What am I doing wrong?


var foodDemand = function(pizza); {
console.log("I want to eat" + " " + pizza);


Hey @codekses,

In foodDemand, it would be easier to put your parameter as food, not pizza. I'll tell you why. :wink:

I'm guessing that you want your foodDemand to be pizza, right? Which is what this is for:


and you would change that to:


For pizza would then be your parameter, in your case pizza.

Which is confusing.

Much easier like this:

var foodDemand = function(food){
console.log("I want to eat" + "" + food);

(Oh yeah, just in case you just copy + paste this code, I made a bit of not having the perfect statement there. It's called copyproof. :wink:)

What this does is that it makes pizza the property for the parameter food, not pizza being the property for the parameter pizza.

Okay, now the REAL problem

The real problem in your situation is that you don't have any value for the parameter pizza.

As said on top, should be like:


Hope it helped!:smiley:


Thanks man!