강의

멘토링

로드맵

Inflearn Community Q&A

tonyjung12191733's profile image
tonyjung12191733

asked

Free Python Tutorial (Basic) - Become a Developer in 6 Hours

one line for

마지막 에러가 뜨네요 뭐가 문제일까요?

Written on

·

361

0

students = ["Iron man""Thor""I am groot"]
 students = [i.upper() for i in students]
 print(students)
File "c:/Users/정태원/Desktop/Pythonworkspace/practice.py", line 10 students = ["Iron man", "Thor", "I am groot"] ^ IndentationError: unexpected indent PS C:\Users\정태원\Desktop\Pythonworkspace>
python

Quiz

71% of people got it wrong. Give it a try!

When is the `else` block executed in an `if-elif-else` structure?

When the `if` condition is true

When the elif condition is true

When all preceding `if` or `elif` conditions are false

On program end

Answer 1

0

2번 째 줄의 students와 print가 한 칸 들여쓰기 되어서 그런 것 같습니다. 파이썬은 들여쓰기 규칙이 매우 엄격해서요~!

tonyjung12191733's profile image
tonyjung12191733

asked

Ask a question