If the counter value is ...

If the counter value is equal to 0, the program will silently terminate.

If the counter value is not equal to 0, the code in Listing 5 will compute and display the average grade as the sum of the grades divided by the number of grades.