STEP 2: Let's now add a loop so we can run our simulation multiple times.

  • In , drag in Loop with Range.
  • In GRAPHICS, go to and drag in Sprite at Position INSIDE your loop.
  • Change the image label from "codester" to "soccerball".
  • Change the x-coordinate from 0 to -160 and the y-coordinate from 0 to -230.

To navigate the page using the TAB key, first press ESC to exit the code editor.

# THIS ACTIVITY IS IN PREVIEW ONLY MODE
  • Run Code
  • Submit Work
  • Next Activity
  • Show Console
  • Reset Code Editor
  • Codesters How To (opens in a new tab)