Skip to content

Instantly share code, notes, and snippets.

@kylekeesling
Created November 6, 2015 21:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kylekeesling/5df807dc976a726e589e to your computer and use it in GitHub Desktop.
Save kylekeesling/5df807dc976a726e589e to your computer and use it in GitHub Desktop.
# Expected output:
# YOU ARE x YEARS OLD IN DOG YEARS
# Calculate dog years:
# 1 dog year = 7 human years
puts "Hello there, what's your age?"
user_age = gets
dog_years = user_age.to_i * 7
output_string = "you are #{dog_years} years old in dog years"
puts output_string.upcase
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment