#!/usr/bin/env ruby -w # # "99 Bottles of Beer on the Wall..." # "Learn to Program" by Chris Pine, p. 55 # bottles = 99 while bottles >= 1 puts "#{bottles} bottles of beer on the wall" puts "#{bottles} bottles of beer" puts "If one of these bottles should happen to fall..." puts "#{bottles - 1} bottles of beer on the wall\n\n" bottles = bottles - 1 end