WARNING: This program has a bug, which means we need to fix it!

RULE: All 3 if statements should be nested (indented four spaces) inside the loop. We can put loops and if statements inside of other loops and if statements. The code INSIDE of those statements will be indented twice.

  • Click Run and play the game to see what's wrong. The fish only responds after all three guesses!
  • Debug this program so that the sprite gives a response for each guess.

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)