Infogain interview question

Python list comprehension and basic python knowledge