1a
Write one line of Python that makes a new list holding only the even elements of a, and print it.
Hint 1
The slide Filtered List Comprehension shows the if clause at the end of a comprehension.
Check your output
[4, 16, 36, 64, 100]Show solutionHide solution
print([x for x in a if x % 2 == 0])