/* This program prints the names of lakes and a bar graph to show the volumes of the lakes. */ #include main() { char c; int vol; /* volume in hundreds of cubic miles of lake */ int i; /* loop counter */ while ( scanf( " %c", &c ) != EOF ) { do { /* print name of lake */ printf( "%c", c ); scanf( "%c", &c ); } while ( c != '\n' ); printf( "\n" ); scanf( "%d", &vol ); /* get volume of lake */ for ( i = 1; i <= vol; i++ ) /* print stars */ printf( "*" ); printf( "\n\n" ); } }