Contact: aviboots(AT)netvision.net.il
39,990 questions
51,935 answers
573 users
dict = {'key1':34, 'key2':89, 'key3':12, 'key4':72} print(dict) del dict['key2'] print(dict) ''' run: {'key1': 34, 'key2': 89, 'key3': 12, 'key4': 72} {'key1': 34, 'key3': 12, 'key4': 72} '''
dict = {'key1':34, 'key2':89, 'key3':12, 'key4':72, 'key5':100} print(dict) dict.pop('key2') print(dict) ''' run: {'key1': 34, 'key2': 89, 'key3': 12, 'key4': 72, 'key5': 100} {'key1': 34, 'key3': 12, 'key4': 72, 'key5': 100} '''