dictionaries

PHOTO EMBED

Mon Jan 03 2022 11:11:05 GMT+0000 (Coordinated Universal Time)

Saved by @ahoeweler

# create dict by two lists
list1 = [1, 2, 3]
list2 = [4, 5, 6]

dict = {'list1': list1, 'list2': list2}

# delete key in dict
del(dict[key])

# access nested dicts
dict1[key1][key2]

# update existing keys
dict1[key1] = 'string'
content_copyCOPY