Created
June 28, 2016 05:31
-
-
Save jrunning/df00de328d53a2a5b67db96616a8f870 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This... | |
if x == y and y == z | |
puts "This triangle is equilateral" | |
else | |
if x == y or y == z or x == z | |
puts "This triangle is isoceles" | |
else | |
if x != y and y != z and x != z | |
puts "this triangle is scalene" | |
end | |
end | |
end | |
# ...is not the same as this... | |
if x == y and y == z | |
puts "This triangle is equilateral" | |
elsif x == y or y == z or x == z | |
puts "This triangle is isoceles" | |
elsif x != y and y != z and x != z | |
puts "this triangle is scalene" | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment