To wrap up this lesson, let’s create our own for/else statement from scratch.



Build your for/else statement in the editor. Execution of the else branch is optional, but your code should print a string of your choice to the editor regardless.

Take this course for free

Mini Info Outline Icon
By signing up for Codecademy, you agree to Codecademy's Terms of Service & Privacy Policy.

Or sign up using:

Already have an account?