Or Equal
Submitted By:
david
Difficulty:
Elementary
Tags:
operators
Instructions:
In Ruby, the combination of "||=" has some great uses. It also has some limitations too though.
Code:
b = 8 c = false a ||= "rubeque" b ||= "rubeque" c ||= "rubeque" assert_equal a, "rubeque" assert_equal b, 8 assert_equal c, ___
Your Solution
Back to Problems
