Deleting a few list items inside of dictionary
Hi, I have a dictionary:
phone = {\"first\":100,\"second\":200,\"third\":[10,12,5,38],\"fourth\":400}
You can treat phone["third"] as a list since that is what it evaluates to. For instance, if you know the indexes of the items you want to remove you can do:
phone["third"][1:3]=[]
or
del phone["third"][1:3]