Advertisement
Guest User

Untitled

a guest
Feb 22nd, 2019
91
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. def prompt
  2. print ">> "
  3. end
  4.  
  5. puts "welcome to the weight-calc 3000! Enter you weight below!"
  6.  
  7. prompt; weight = Integer(gets.chomp())
  8.  
  9. if weight > 100 && weight < 300
  10. puts "your healthy!"
  11. elsif weight > 300
  12. puts "your fat"
  13. elsif weight < 100
  14. puts "your skinny"
  15. elsif weight == 150
  16. puts "your perfect"
  17. end
  18.  
  19. if weight > 100 && weight < 300
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement