Saved Bookmarks
| 1. |
If a is a dictionary with some key-value pairs, what does a.popitem() do?(a) Removes an arbitrary element(b) Removes all the key-value pairs(c) Removes the key-value pair for the key given as an argument(d) Invalid method for dictionary |
|
Answer» Right option is (a) Removes an arbitrary element Explanation: The method popitem() removes a random key-value pair. |
|