a XX bottles of beer on the wall. XX bottles of beer on the wall, XX bottles of beer, Take one down, pass it around, /^\$/d e|@e 9 8 7 6 5 4 3 2 1 0 $ ya b|$put b|$s/. // @c|@c|@c|@c|@c|@c|@c|@c|@c . $d d|$d c|@d $-9,$s/^\(.\).*/X\1/ /^X9/,ya y $-9,s=^X\(.\)$=s/X/\1/= $-9,s=^=$put y|$-9,$= /^\//d c|@d|@c /^90/ma f|/^89/,/^80/mo 'f 6,$s=^..$=$put y|%s/^XX/&/= 1,5d y g/^\$/d e|@e 1,2d %s/^0// $s/.*/Go to the store, buy some more./ %s/^1 bottles/1 bottle/ %p