Do you ever find yourself writing something like this?
>>> squares = []
>>> for n in range(5):
...    squares.append(n ** 2)
[0, 1, 4, 9, 16]>>> [n ** 2 for n in range(5)]
[0, 1, 4, 9, 16]if clause:
>>> [n ** 2 for n in range(5) if n % 2 == 0]
[0, 4, 16]For more info, see this pythonforbeginners.com post.