A Relevant Pattern
where
a : /* Initialize 101 counters to 0. */
b : /* Increment counter for grade. */
g : /* Print histogram. */
/* �Process� grades until (but not including) a stopping signal of -1. */
a
grade = in.readInt();
while (grade != -1 )
{
b
grade = in.readInt();
}
g
int grade; // the grade being processed.
Previous slide
Next slide
Back to first slide
View graphic version