9 Functions with two parameters


#1

var perimeterBox = function(length, width) {
return length + length + width + width;
};

This is my code I do not really understand what is wrong or what silly mistake I am making, someone give me some guidance?


#2

There seems to be nothing wrong with your function. Are you maybe forgetting to call it?


#3

Did you add the number 4 instruction? i believe not.

04.Call the function and pass in any value for length and width you like.

You can declare a variable that will holds your function and pass a value for you length and width. And use console.log() method to display data.

example:
var newPerimeter = perimeterBox(1,1);
console.log(newPerimeter)
;


#4

var perimeterBox = function(length, width) {
return length + length + width + width;
}
console.log("perimeterBox")

Im guessing this is still wrong haha.
im bad at this


#5

Take a look on the reply post, hope that helps.
Again, You can declare a variable that will holds your function and pass a value for you length and width. And use console.log() method to display data.


#6

Sorry my fault, remove the double quote on console.log("newPerimeter");


#7

Ive managed now, thanks for the help


#9

lollololololololololol