Register Now

Login

Lost Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

What is the output of the given code?
Ans=Ruby
puts “#[Ans] is an oop language”

What is the output of the given code?
Ans=Ruby
puts “#[Ans] is an oop language”
a) Error, no output
b) Ruby is an oop language
c) Warning:already initialized constant Ans
d) None of the mentioned

Answer: b
Explanation: Curly braces {} are used for printing the value instead of square braces [].
Output:
(ruby): warning: already initialized constant Ans

Join The Discussion