Tuesday, September 12, 2006

I sure as hell hope this is on the test.

#include <stdio.h>

int main()
{
     /* Declare variable */
     float beers ;
     for (beers = 100; beers != 0; beers -= 1)
     {
          printf("%f %s\n %f %s\n",
               beers, "bottles of beer on the wall",
               beers, "bottles of beer",);
          printf("Take one down, pass it around\n");
          printf("%e bottles of beer on the wall\n\n", beers - 1 );
     }

     return
}

2 comments:

Feng said...

You forgot the semicolon after return. Also I don't think there's such a thing as %e.

Kinezumi-Risu said...

...This is our professor's code, not mine.

Though, none of us were really paying attention, 'cause that class is just so boring, but I'm pretty sure you're right about the %e thing.