Sorry folks, forgot to mention that this has already been addressed in the Errata section. However, the correction in the Errata section only mentions the missing

**not** so the result is even integers, instead of even squares:

Code:

>>> result = []
>>> for n in range(1,11):
... if not n*n % 2: # "not" now included.
... result.append(n) # n*n still missing.
...
>>> print(result)
[2, 4, 6, 8, 10] # Even integers instead of even squares.