In Python dictionary, del keyword is used to delete a particular element. The clear( ) function is used to delete all the elements in a dictionary. To remove the dictionary, we can use del keyword with dictionary name.
Dict={‘Roll No’: 12001, ‘SName’: ‘Meena’ , ‘Mark1’: 98, ‘Mar12’: 86}
print(“Dictionary elements before deletion: \n” , Dict) del Dict[‘Mark1’]
# Deleting a particular element Dict.clear( )
# Deleting all elements