Skip to content

Instantly share code, notes, and snippets.

@MrBerg
Created February 27, 2014 15:48
Show Gist options
  • Save MrBerg/9252704 to your computer and use it in GitHub Desktop.
Save MrBerg/9252704 to your computer and use it in GitHub Desktop.
Implementation of 99 bottles in ArnoldC. The number of bottles and the rest of the line are printed on separate lines, due to there being no string concatenation or printing on the same line implemented in ArnoldC (yet).
IT'S SHOWTIME
HEY CHRISTMAS TREE bottlesOfBeer
YOU SET US UP 99
HEY CHRISTMAS TREE isLargerThan1
YOU SET US UP @NO PROBLEMO
STICK AROUND isLargerThan1
TALK TO THE HAND bottlesOfBeer
TALK TO THE HAND "bottles of beer on the wall,"
TALK TO THE HAND bottlesOfBeer
TALK TO THE HAND "bottles of beer. Take one down and pass it around, "
GET TO THE CHOPPER bottlesOfBeer
HERE IS MY INVITATION bottlesOfBeer
GET DOWN 1
ENOUGH TALK
GET TO THE CHOPPER isLargerThan1
HERE IS MY INVITATION bottlesOfBeer
LET OFF SOME STEAM BENNET 1
ENOUGH TALK
BECAUSE I'M GOING TO SAY PLEASE isLargerThan1
TALK TO THE HAND bottlesOfBeer
TALK TO THE HAND "bottles of beer on the wall."
TALK TO THE HAND ""
BULLSHIT
TALK TO THE HAND bottlesOfBeer
TALK TO THE HAND "bottle of beer on the wall."
TALK TO THE HAND ""
TALK TO THE HAND bottlesOfBeer
TALK TO THE HAND "bottle of beer on the wall,"
TALK TO THE HAND bottlesOfBeer
TALK TO THE HAND "bottle of beer. Take one down and pass it around, "
TALK TO THE HAND "no more bottles of beer on the wall."
TALK TO THE HAND ""
YOU HAVE NO RESPECT FOR LOGIC
CHILL
TALK TO THE HAND "No more bottles of beer on the wall, no more bottles of beer."
TALK TO THE HAND "Go to the store and buy some more, 99 bottles of beer on the wall."
YOU HAVE BEEN TERMINATED
@mikedfunk
Copy link

👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment