Function with two parameters


what if we write, it ain't working

var perimeterBox = function(length,width){
var perimeter = length*2 +width*2;



The code you presented is valid...
but it might be that the code-checker will give you an Oops-message
as it expects you to do as is asked in the Instructions.....


as @leonhard_wettengmx_n said. The error you're receiving is based on how you presented the code, and how the console expected to read the code.


03. One formula for perimeter is length + length + width + width;

Hopefully that will help.


Thanks @leonhard_wettengmx_n


thanks @lolman for help


@leonhard_wettengmx_n @lolman is it necessary that we use "return" we can use "console.log" also?? for function untill and unless it's not mention to use any of them


console.log(); is only for the programmer to help debug code. It wouldn't be used in a final project, so I'd get use to just using return unless the JavaScript lesson wants you to do so.


@lolman ehanks buddy got it