✅ 문제 1. 변수와 자료형
[문제] 빈칸에 들어갈 코드를 완성하세요.
() = "Hello, Python"
() = 42
print(greeting)
print(age)
[풀이]
(greeting) = "Hello, Python"
(age) = 42
print(greeting)
print(age)
🔻🔻🔻 문제 분석 🔻🔻🔻
✅ 문제 2. 리스트와 인덱스
[문제] "banana"를 출력하세요.
fruits = ["apple", "banana", "cherry"]
print(fruits[])
[풀이]
fruits = ["apple", "banana", "cherry"]
print(fruits[1])
🔻🔻🔻 문제 분석 🔻🔻🔻
✅ 문제 3. 딕셔너리
[문제] "Alice"를 출력하세요.
student = {"name": "Alice", "age": 20}
print(student[])
[풀이]
student = {"name": "Alice", "age": 20}
print(student["name"])
🔻🔻🔻 문제 분석 🔻🔻🔻
✅ 문제 4. if 조건문
[문제] 빈칸에 들어갈 코드를 완성하세요.
x = 10
if x > 5:
print("x is greater than 5")
else:
print()
[풀이]
x = 10
if x > 5:
print("x is greater than 5")
else:
print("x is less than or equal to x")
🔻🔻🔻 문제 분석 🔻🔻🔻
✅ 문제 5. for 반복문
[문제] 빈칸에 들어갈 코드를 완성하세요.
colors = ["red", "green", "blue"]
for () in colors:
print()
[풀이]
colors = ["red", "green", "blue"]
for (color) in colors:
print(color)
🔻🔻🔻 문제 분석 🔻🔻🔻