- script.js
JavaScript
var food = 'pies';
var eatDinner = function () {
console.log('I ate ' + food);
};
Result
Goalscompleted
- After the
eatDinner
function is defined, call this function. - Change the value of the variable
food
to'vinaigrette salad'
later in the code after the function call. - After that once again call the
eatDinner
function.
Comments