Table-5a Inside Outside

< CS101

Inside/Outside Loop Experiment - Om Nom Nom Nom

Let's look again at the importance of inside vs. outside of loops.


tablea5-1

 

Experiment solutions:

  Location 1: 1  (outside the loop, before it)
  Location 2: 2000 (in the loop, not in the if-body)
  Location 3: 12  (in the if-body)
  Location 4: 1  (outside the loop, after it)