Question 1 of 25
Hints left: 3
Q1
What symbol is used to denote comments in Ruby?
Q2
What is the correct syntax for creating a hash in Ruby?
Q3
Which of the following is the correct way to start a single-line comment in Ruby?
Q4
How do you add two numbers in Ruby?
Q5
In Ruby, what is the keyword used to define a class?
Q6
Which of the following is a valid variable name in Ruby?
Q7
What is the default file extension for Ruby files?
Q8
What is the correct syntax for defining a variable in Ruby?
Q9
What symbol is used to denote the end of a statement in Ruby?
Q10
Which symbol is used to concatenate strings in Ruby?
Q11
How do you access a value from a hash in Ruby?
Q12
What does the 'gets' method do in Ruby?
Q13
Which method is used to convert a string to uppercase in Ruby?
Q14
Which of these operators is used for string concatenation?
Q15
What are the different types of comments in Ruby?
Q16
What does the 'print' method do in Ruby?
Q17
What is the correct syntax for printing a message to the console?
Q18
What is the correct way to define a conditional statement in Ruby?
Q19
In Ruby, what is the keyword used to define a method?
Q20
Which of the following is the correct way to define a constant in Ruby?
Q21
Which of the following is NOT a valid data type in Ruby?
Q22
What does the 'puts' method do in Ruby?
Q23
How do you call a method in Ruby?
Q24
What is the correct way to define a method in Ruby?
Q25
What is the correct way to declare a variable in Ruby?