99 Bottles of beer
August 14, 2013 - 11:49 pm by Joss Whittle L2Program LanguageStill very much a work in progress but it’s at least 99% there. And what better way to celebrate than with a round of 99 bottles of beer on the wall!
1.1 Do part 2 for a = 99(-1)2.
1.2 Do part 3.
1.3 Line.
2.1 Type a in form 1.
2.2 Type a in form 2.
2.3 Do step 4.1.
2.4 Set b = a - 1.
2.5 Do step 3.1 if b = 1.
2.6 Do step 3.5 if b != 1.
2.7 Line.
3.1 Type "1 bottle of beer on the wall".
3.2 Type "1 bottle of beer".
3.3 Do step 4.1.
3.4 Set b = 0.
3.5 Type b in form 1.
4.1 Type "You take one down, you pass it around".
Form 1:
_._ bottles of beer on the wall
Form 2:
_._ bottles of beer