Problem 1 Solution: Maximum Number With A For-Loop
A for-loop is useful when the number of iterations (repetitions) is known before the loop begins. The function must "remember" the largest number seen at any point in the data entry. The variable max stores the largest number entered, and the program updates it whenever the user enters a larger number. The challenge is determining how to initialize max. The two functions solve the problem in different ways.