Quiz Complete, well Done!
What is the output of the following code?
dict = {'a': 1, 'b': 2, 'c': 3}
print('a' in dict)
What is the syntax for creating a dictionary in Python?
What is a dictionary in Python?
In a Python dictionary, what are the keys and values?
What does the method 'keys()' do in Python?
Which of the following is NOT a valid key type for a Python dictionary?
What is a dictionary in Python?
What happens if you try to access a key that does not exist in a dictionary using the 'get' method?
What is the time complexity of accessing an element in a dictionary?
What does the method 'items()' do in Python?
What is the output of the following code?
dict = {'a': 1, 'b': 2, 'c': 3}
print(len(dict))
What happens if you try to add a key-value pair to a dictionary using an existing key?
Which of the following is NOT a valid key type for a dictionary?
How do you add a new key-value pair to an existing dictionary?
What does the method 'keys()' do in Python?