Something went wrong

Report a typo

The code below is supposed to print each letter of a word from the input on a new line if this letter is not 'a'. Unfortunately, the SyntaxError is raised. Analyze the code and correct some errors!

Sample Input 1:

cat

Sample Output 1:

c
t
Write a program in Python 3
word = input()
for letter in word
if letter != 'a'
print(letter)
___

Create a free account to access the full topic