Output printed twice


#1

code :-
var perimeterBox =function (len , wid)
{
console.log(len + len + wid + wid );
};
perimeterBox(1,1);

output :-
4
4

error :-
Oops, try again. It looks like your perimeterBox function doesn't return the correct perimeter (4) for a width of 1 and a length of 1.


#2

@pysurfer02955,

Maybe you will have to use the return-statement instead of using the console.log() method.

For an explanation, of more output in your display
please read
= http://discuss.codecademy.com/t/6-8-a-question-of-why-i-get-the-result-i-get/10666/10?u=leonhard_wettengmx_n3