Interactive Programming Challenge

Debug the code and find the correct solutions!

Question 1 of 3
Easy
Score: 0/3
List Comprehension Bug
Python

This code should create a list of squares for even numbers, but it has a bug:

numbers = [1, 2, 3, 4, 5, 6]
result = [x**2 for x in numbers if x % 2 = 0]
print(result)

What's the bug in this code?