I have no idea what I am doing wrong


#1


SyntaxError: unexpected token:


var greeting = function (name) {
    console.log("Great to see you," + " " + name);
};

// On line 11, call the greeting function!
var greeting = function(Anthonie) {
    console.log("Great to see you," + " " + "Anthonie"):
};


#2

Just write greeting("Antonie"); calls the greeting function with "Anthonie" paramater as name.


#3

Hello

Delete the :

console.log("Great to see you," + " " + "Anthonie"):
Your error says - SyntaxError: unexpected token:


#4

Calling the function means writing the name of the function and passing it an argument. The argument is what goes in the parameter field when you want to use the function. Let's say you made a function called eatStuff:

var eatStuff= function(stuff){
console.log("i like to eat " + stuff);
}

You would call it by writing:

eatStuff("buildings");


#5

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