Packing Your Bag

Hi, I’m having a problem with the ‘Pack Your Bag’ code. Can someone tell me what I am doing wrong.

1 Like

Isn’t it supposed to be like this?

var myBackpack = {
food: ‘bananas’,
equipment: ‘map’,
clothing: ‘hat’
}

Each property (e.g. food) is assigned a string (e.g. bananas) as a value.
The way you’ve written it, the food property is assigned a print(‘bananas’) function?

I’d say that’s incorrect but can the experts chime in? Can we assign functions to a property or is there simply no use case there?

Thanks that helped. I can finally get past it now