Theory
Write true/false: Are python dictionaries mutuable?
True
Identify the italic part: d= {"India": "Delhi", "Germany":"Berlin", "Italy":"Rome"}
Key
Which built-in function is used to create a dictionary from a given sequence of elements and values?
fromkeys()
a= {"B":5, "A":9, C:7}
sorted(a)
Error
a={1:"Ant",2:"Ball",3:"Cat",4:"Dog"}
print(a.pop(4,9))
Dog
a= {1:"A", 3:"B", 6:"C",7:"D"}
print(a.get(2,4))
4
d= {"Class":20, "Sports":8}
To delele "Sports", what command should be used?
del d["Sports"]