What is the output of the following code?
$var = 1
print "1 -- Step 1\n" if $var
print "2 -- Step 2\n" unless $var
$var = false
print "3 -- Step 3\n" unless $var
Correct Answer:
1 -- Step 1
3 - Step 3
Explanation:
Note: This Question is unanswered, help us to find answer for this one
More Ruby MCQ Questions