1# PYTHON DICTIONARY METHODS
2METHOD DESCRIPTION
3clear() Removes all the elements from the dictionary
4copy() Returns a copy of the dictionary
5fromkeys() Returns a dictionary with the specified keys and value
6get() Returns the value of the specified key
7items() Returns a list containing a tuple for each key value pair
8keys() Returns a list containing the dictionary's keys
9pop() Removes the element with the specified key
10popitem() Removes the last inserted key-value pair
11setdefault() Returns the value of the specified key. If the key does not exist:
12 insert the key, with the specified value
13update() Updates the dictionary with the specified key-value pairs
14values() Returns a list of all the values in the dictionary
1#Dictionary methods
2
3clear() - Removes all the elements from the dictionary
4copy() - Returns a copy of the dictionary
5fromkeys() - Returns a dictionary with the specified keys and value
6get() - Returns the value of the specified key
7items() - Returns a list containing a tuple for each key value pair
8keys() - Returns a list containing the dictionary's keys
9pop() - Removes the element with the specified key
10popitem() - Removes the last inserted key-value pair
11setdefault() - Returns the value of the specified key. If the key does not exist: insert the key, with the specified value
12update() - Updates the dictionary with the specified key-value pairs
13values() - Returns a list of all the values in the dictionary
14
15