Skip to content

Instantly share code, notes, and snippets.

@cob16
Created April 19, 2016 20:51
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 cob16/c4ce582e406326e43fe9034b648c55b5 to your computer and use it in GitHub Desktop.
Save cob16/c4ce582e406326e43fe9034b648c55b5 to your computer and use it in GitHub Desktop.
refrain = ' bottles of beer'
refrain1 = ' on the wall! '
bottles = 99
bottles.downto(1) do |i|
puts i.to_s + refrain + refrain1 + i.to_s + refrain
puts 'you take one down, pass it around'
puts (i-1).to_s + refrain + refrain1
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment