It's Dangerous to go alone, Take This


#1

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

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'
inventory['pouch'].sort() 
inventory['backpack'].sort()

Your code here
inventory['backpack'].remove("dagger")
inventory['gold']= inventory['gold'] + 50

#2

I do absolutely NOT know how to do this...


#3

I tried, and Failed WONDERFULLY!


#4

some of your lines seems to be comments, but no # to turn it into a actual comment, see this code:

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

#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'
inventory['pouch'].sort() 
inventory['backpack'].sort()

#Your code here
inventory['backpack'].remove("dagger")
inventory['gold']= inventory['gold'] + 50

i turned the lines which are comments into a comment by using #


#5

yeah Thank you. I have the answer now. AND I DO REMEMBER:

 We do not tolerate cheating!

Please do not just post answers, or ask for them. Some people may help you by posting some code or showing you errors, but cheating is not tolerated. If we see anybody cheating we will delete the post, and maybe ban your account.

#6

i explained it, i said i turned the lines which where not programming language into actual comments, all i did where adding some # and explaining why i did that. That is not cheating, if you think it is, flag it as inappropriate, this will let the other moderators know i violated the guidelines, they can decide if i indeed violated the guidelines


#7

I know...... That isn't what I was saying


#8

I was just telling you I remember what you had said to me earlier


#9

okay, good you remember :slight_smile:


#10

Thank you very much.


#11

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