PATCH//NOTES Open it in the app
← All hands-on practice
Python · 8 min

The other result

branch.py prints blocked when the word is in the line, and clear when it is not. Read it, run it, then change the word so you get the other result.

Start it: free, in your browser, no account

What you will do

  1. Read branch.py.
  2. Run branch.py. It prints blocked.
  3. Change the if so it looks for Accepted.
  4. Run branch.py again. It prints clear.

This Python only adds else: directly under if "text" in name:. No elif, and no other test.