DiveHelper Application -- Calculate Dive Scores

In competitive diving (high school level), meets include programs of either 6 dives or 11 dives per swimmer. Each dive receives an individual score and the total score for that diver's performance is the sum of the individual scores.

The individual score is based on two factors, the diver's performance as scored by the judges and the degree of difficulty of the dive. Degrees of difficulty range from 1.2 through 3.5 (1 meter board).

The judges scores range from 0 for a failed dive through 6 for a perfect dive. Dives may be graded by the whole numbers or the halves (ex. 3.5). Only 3 judges scores are used...if a meet includes 5 judges the high score and low scores are thrown out and the dive is based on the remaining three. If there are 7 judges, then the two highest and lowest scores are thrown out. There may be fewer than 3 judges. If so, the scores are averaged, divided by the number of judges and multiplied by 3. There will never be 4 or 6 judges and never more than 7.

Your task is to thoroughly test the calculation program to be sure that it is ready to calculate individual dive scores prior to the upcoming swim season. This application will be part of a larger meet scoring application.

Step 1 - Black box test

Design a set of test cases that will test the DiveHelper application. For each case, provide an array of scores from the judges and the dive degree of difficulty. Then predict what the result should be or what the behavior should be.

Step 2 - Code Walkthrough

Inspect the code. Where are there potential flaws in the design of the code (some that we may have discovered in the first part, some that you suspect will be an issue in the second part?

Step 3 - White box test

Given the code that you see in front of you, design test cases that will test all aspects of the program. Again, provide an array of judges scores and the dive degree of difficulty. Then predict what the result should be or what the behavior should be.

USA Diving Web Site