next up previous
Next: Looping Control Structure Up: CS101 Lecture 5 Previous: Approach 1: Compare consecutive

Approach 2: Compare last with all above

Work this method by hand.

Summarizing:

We need to understand ``repeated'' execution of same statements (called LOOPS). Then we can write above cleanly!



G. Sivakumar 2000-08-13