An Elegant Solution, revisited
int grade; // the grade being processed.
// For i in 0..100, freq[i] is # of grades of i.
int[] freq = new int[101];
/* �Process� grades until (but not including) a stopping signal of -1. */
/* Initialize 101 counters to 0. */
for ( grade = 0; grade<=100; grade++ )
/* Increment counter for grade. */
System.out.println(�Grade Frequency�);
for ( grade = 0; grade<=100; grade++ )