#4 whats wrong?


#1


https://www.codecademy.com/courses/javascript-beginner-en-6LzGd/0/4?curriculum_id=506324b3a7dffd00020bf661


what am i doing wrong! stuck thingy dosnt help!


// Write your foodDemand function below.
// Last hint: In your reusable block of code, end each line
// with a semicolon (;)
var functionName = function("food"){
    function functionName
   console.log("I want to eat" + "functionName" + "food");
   console.log("I want to eat" + "functionName" + "food");
   console.log("I want to eat" + "functionName" + "food");
}


#2

For starters...

Declare your function and call it foodDemand.

Check the name of your function.

You can call the parameter anything you like. But we'll call it food because that is the thing that is going to change each time we call the function.

A parameter takes the form of a variable, not a string.

... function (food)

Suggest remove the code you have and start over. Read the instructions carefully and don't draw upon the example for anything other than something to look at. Forget the whole "functionName" thing.


#3

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