Comprehensions are used for writing cleaner, faster code! Here’s how they work .
#PythonComprehensions #PythonProTips
numbers = [1, 2, 3, 4, 5]
squares = [x**2 for x in numbers] # List
even_squares = {x: x**2 for x in numbers if x % 2 == 0} # Dictionary