Ruby conditionals - if else statement
- else
x = 1
y = 2
if x == y
puts "They are equal"
else
puts "They are not equal"
end
Press ← or → to navigate between chapters
Press S or / to search in the book
Press ? to show this help
Press Esc to hide this help
x = 1
y = 2
if x == y
puts "They are equal"
else
puts "They are not equal"
end