Vidyalelo
Ruby Programming · Q63

Control Structures in Ruby

Programming · Ruby Programming · question 63

Q63

What is output of the given code? counter=-3 if counter 5 puts (counter) counter=2*counter puts(counter) end

A.
-3
-2
Answer
B.
-3
-6
C.
Syntax error
D.
None of the mentioned

Answer: Option A

Solution

Answer: Option A
No explanation is given for this question Let's Discuss on Board