Question
What is the output of the given code?a=true b=false if a && b puts "False" elsif a || b puts "True" else puts "neither true nor false" end
Answer: Option B
Was this answer helpful ?
True or false will always evaluate to true, hence the elsif block is executed.
Was this answer helpful ?
Submit Solution