About Lesson
Deleting Dictionary:-
Dictionary को delete करने के लिए del keyword का उपयोग किया जाता है
a={50:’Aman’, 51:’Raman’, 52:’Suman’}
print(a) # {50: ‘Aman’, 51: ‘Raman’, 52: ‘Suman’}
del a
print(a) # NameError: name ‘a’ is not defined
Deleting Dictionary:-
del keyword is used to delete the dictionary.
a={50:’Aman’, 51:’Raman’, 52:’Suman’}
print(a) # {50: ‘Aman’, 51: ‘Raman’, 52: ‘Suman’}
del a
print(a) # NameError: name ‘a’ is not defined