
Reet C. answered 04/09/19
Computer Engineer With A Passion For Teaching!
You can also just use the square bracket notation:
Reet C. answered 04/09/19
Computer Engineer With A Passion For Teaching!
You can also just use the square bracket notation:
Eddie B. answered 03/20/19
Purdue University student studying computer engineering
It can be done fairly easily using the update method. If you have the dictionary
dict1 = {'firstKey' : 'blank1' , 'secondKey' : 'blank2'}
You can add by doing this
dict1.update({'thirdKey' : 'blank3'})
This also works if you want to combine two dictionaries by doing something like
dict1.update(dict2)
Get a free answer to a quick problem.
Most questions answered within 4 hours.
Choose an expert and meet online. No packages or subscriptions, pay only for the time you need.