Each letter on its own line
This page needs a recent browser (with SharedArrayBuffer support). Please update Chrome, Edge, Firefox or Safari to the latest version.
This one builds on a lesson you haven't finished yet. Do that lesson first:
Python Basics · Counting loops →
Each letter on its own line
word is "cat". Use a for loop to print each of its letters on its own line.
A for loop can walk straight through a string — no numbers needed. for letter in word: gives you one character each turn.
word is "cat". Use a for loop to print each of its letters on its own line.
Click Run to see the output here.