This is the nature of the variables or structures which will be used to store information. We will need variables for input times and distances, for the total distance and time and for the calculated average. Processes The main processing control will be a loop which allows the input of a number of distances and times. Assumptions We need to make assumptions if any part of the problem is ambiguous. For example, the problem gives no indication of whether the distances and times are integers or can contain fractional parts.
Lets assume the latter.
The problem does not specify how the user will terminate the input. Let's assume that the input of a negative distance will signal the end of input. The design of the solution sets out the logical steps which would be followed in a computer program. Test We test our design with a desk test . That is, we run the algorithm by hand, using sample inputs and do the calculations manually.