Home / Programming MCQs / Ruby MCQs / Question
Y
Q. What will be the output of the given ruby code?
array = [100, 200, 300, 400, 500] print array[4]
Explanation:
Array's index start from 0 so array[4] will give 500.
You must be Logged in to update hint/solution
Which statement can be used to take any input from the user from standard screen?
What does the term "lexical scope" refer to in Ruby?
How do you find the number of milliseconds between two Time objects in Ruby?
What is the output of given code? string="I'am Learning RUBY Language".downcase string.upcase
What does the `retry` keyword do when used within a loop in Ruby?
Double quotes and single quotes will interpolates ?
What does the term "DRY" stand for in Ruby programming?
Discusssion
Login to discuss.