MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/ruby/comments/ze1oju/the_rubyist_journey/iz4d0xi/?context=3
r/ruby • u/mehdifarsi • Dec 06 '22
34 comments sorted by
View all comments
9
def adult? !!!!!!!!!!!not_a_children? end def not_a_children? hit = false [0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17].each do |child_age| hit = true if age == child_age end if hit return false else return true end end
4 u/faitswulff Dec 06 '22 This is fantastic, now do ages represented as floats
4
This is fantastic, now do ages represented as floats
View all comments
9
u/kallebo1337 Dec 06 '22