The Full Wiki



More info on 99 Bottles of Beer computer program

99 Bottles of Beer computer program: Wikis


Note: Many of our articles have direct quotes from sources you can cite, within the Wikipedia article! This article doesn't yet, but we're working on it! See more info or our list of citable articles.
A 99 Bottles of Beer computer program is a common programming exercise. The idea is to program a routine writing out the full lyrics of "99 Bottles of Beer".


Example in C :

int main() {
int i;

for(i = 99; i > 0; --i) {
cout i << " bottles of beer on the wall\n";
cout i << " bottles of beer!\n";
cout "Take one down, pass it around. " << (i-1) << " bottles of beer on the wall!\n"
}
return 0;
}

Related topics

  • Hello world program


  • External links

  • 99 Bottles of Beer in hundreds of programming languages











  • Got something to say? Make a comment.
    Your name
    Your email address
    Message
    Please enter the solution to case below
    45-15=