Skip to content

Instantly share code, notes, and snippets.

class BottlesOfBeer
def count_off
puts "How many bottles of beer have you got? "
numbers = gets.chomp.to_i
numbers.downto(1) do |number|
puts "#{number} bottles of beer on the wall, #{number} bottles of beer! Take one down, pass it around, #{number-1} bottles of beer on the wall!"
end
end
bottle = BottlesOfBeer.new