equal
deleted
inserted
replaced
28 52.53 |
28 52.53 |
29 |
29 |
30 To add a new key-value to this dictionary we have to something like |
30 To add a new key-value to this dictionary we have to something like |
31 player['Name'] = 'Rahul Dravid' |
31 player['Name'] = 'Rahul Dravid' |
32 print player |
32 print player |
33 Please dont forget that Python dictionaries dont maintain the order |
33 Please remember that Python dictionaries dont maintain the order |
34 in which key-value pair are stored it changes as we add new entries. |
34 in which the key-value pair are stored it might change as we add new |
|
35 entries. |
35 |
36 |
36 In dictionaries Duplicate keys are overwritten, that is when we do |
37 In dictionaries Duplicate keys are overwritten, that is when we do |
37 player['Mat'] = 139 |
38 player['Mat'] = 139 |
38 It wont create a new entry, rather it will simply overwrite previous |
39 It wont create a new entry, rather it will simply overwrite previous |
39 value with new one. So |
40 value with new one. So |