9. Functions and two parameters


#1

Help please, Im getting a syntax error: unexpected number

var perimeterBox = function (2, 2) {
return 2 * 2;
};
console.log(perimeterBox(2 * 2));


#2

here:

var perimeterBox = function (2, 2)

function parameter should be variables, not integers


#3

Hello man here is my code -->

var permimeterBox = function(2 , 2) {
return 2*2; }

console.log(perimeterBox(5, 2))

can't understand my mistake, may I have some help please ?


#4

Well, you can read the answer i already posted here:
`

that should help you, given you have the exact same issue. You didn't indicate you read this, and that you have question about this explanation


#5

Fund out what was wrong just after posting ! Thanks !


#6