The while loop

(Display Listing 2.)

If the value of testResult is true, the code in the body of the loop is executed once.

The code in the body of the loop consists of two sequential actions:

  1. Cause the penguin to display "Even, keep on looping" on the screen for two seconds.
  2. Update the value of the variable named testResult by asking the user to enter another integer using the same code as before.