Complete the code to create an empty dictionary named my_dict.
my_dict = [1]Use curly braces {} to create an empty dictionary in Python.
Complete the code to create a dictionary person with keys 'name' and 'age'.
person = [1]Dictionaries use curly braces with key-value pairs separated by colons.
Fix the error in the dictionary creation code.
data = [1]Dictionary keys and values are separated by colons, not equal signs. Keys must be quoted strings or valid identifiers.
Fill both blanks to create a dictionary squares mapping numbers 1 to 3 to their squares.
squares = { [1]: [2] for [1] in range(1, 4) }Use the same variable x for keys and values, with values as x**2 for squares.
Fill all three blanks to create a dictionary filtered with keys as uppercase words and values as their lengths, only for words longer than 3 letters.
filtered = { [1]: [2] for word in words if len(word) [3] 3 }< instead of > in the condition.Keys are uppercase words, values are lengths, and filter keeps words longer than 3 letters.