pop method returns the value corresponding to a given key, and then remove the key-value pair from the dictionary : Pop : Dictionary PYTHON TUTORIALS


PYTHON TUTORIALS » Dictionary » Pop »

 

pop method returns the value corresponding to a given key, and then remove the key-value pair from the dictionary


d = {'x'1'y'2}
d.pop('x')
print d



Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .


PYTHON TUTORIALS

 Navioo Dictionary
» Pop