4. How does a function work? {STUCKED}


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

Let's make a function that tells the world what you want to eat.

Declare your function and call it foodDemand.
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.
Your reusable block of code follow this. Surround it with the right brackets. The code you want to repeat is: console.log("I want to eat" + " " + food);
Call the function and put in a specific food you want!


Almost good but instead of this:


better call the function from outside of it by: