Created
September 29, 2015 21:47
-
-
Save RobertCam/53eb4274bfb7bead9715 to your computer and use it in GitHub Desktop.
Vancouver yuppie apartment method
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
# must be baller and either furnished or rent cheaper than 2100 | |
def rent?(furnished, rent, baller) | |
baller && (furnished || rent < 2100) | |
end | |
puts rent?(true, 2000, true) | |
puts rent?(false, 2000, true) | |
puts rent?(true, 2500, true) | |
puts rent?(true, 2000, false) | |
puts rent?(true, 2500, false) | |
puts rent?(false, 2500, true) | |
puts rent?(false, 2000, false) | |
puts rent?(false, 2500, false) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment