Rotate your phone or change to desktop for better experience

Rotate your phone or change to desktop for better experience

4. Demonstrate use of Dictionaries

 Employee = {"Name": "John", "Age": 29, "salary":25000,"Company":"GOOGLE"}

print("Printing Dictionary:")

for x,y in Employee.items():

print(x,y)

print("Lenth of dictionary:",len(Employee))

print("dictionary Keys:",Employee.keys())

print("dictionary values:",Employee.values())

print("dictionary Items:",Employee.items())

print("dictionary POP:",Employee.pop('salary'))

print("After Pop Item",Employee)

Post a Comment

0 Comments