Its Dangerous to Go Alone!


Edit: Disregard i closed my closed and reopened my browser and tried it again and it works now I keep getting an error saying "Did you accidentally delete 'inventory' dictionary?" and also it says line 18 has a syntax error for adding 50 to gold.

I read through the other topics and i cant figure out why it is an error. Please help!

inventory = {
    'gold' : 500,
    'pouch' : ['flint', 'twine', 'gemstone'], # Assigned a new list to 'pouch' key
    'backpack' : ['xylophone','dagger', 'bedroll','bread loaf']

# Adding a key 'burlap bag' and assigning a list to it
inventory['burlap bag'] = ['apple', 'small ruby', 'three-toed sloth']

# Sorting the list found under the key 'pouch'

# Your code here
inventory['pocket'] = ['seashell', 'strange berry', 'lint']

inventory["gold"] = inventory["gold"] + 50.


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.