What is the best way to remove all keys from a dictionary without deleting the dictionary?
Correct answer
dict.clear()
Explanation
`clear()` empties the dictionary without destroying its reference.
Update: Admin added a tag on this question
Topics
By Admin · · 54 views