One of the nice feature of Python is that it let you create new list from existing list in simple one liners in pythonic way. Python 3 also introduces set and dictionary comprehensions. Also we can use if literal to filter some of the items.
>>> fruits = ['Banana', 'Apple', 'Lime'] >>> loud_fruits = [fruit.upper() for fruit in fruits]
>>> print [i for i in range(10)]
>>> print [i for i in range(20) if i%2 == 0]