Home / Programming MCQs / Ruby MCQs / Question
V
Q. What is true about while loop?
Explanation:
Executes code while conditional is true. A while loop`s conditional is separated from code by the reserved word do, a newline, backslash , or a semicolon.
You must be Logged in to update hint/solution
What does the keys method return when called on a hash in Ruby?
How can you check if a file is readable in Ruby?
Arrays can be used to store multiple values in one single variable.
Default value of class variables is?
Which method is used to convert a collection into an enumerator in Ruby?
What does the protected keyword do in Ruby classes?
What is the correct way to declare and initialize a variable in Ruby?
Discusssion
Login to discuss.