Lesson 24 where is the syntax error ,some one Pl tell me


#1

Below is the code.

function Rectangle(height, width) {
this.height = height;
this.width = width;
this.calcArea = function() {
return this.height * this.width;
};
// put our perimeter function here!
this.calcPerimeter = function() {
return 2 *this.height + 2 *this.width
}

var rex = new Rectangle(7,3);
var area = rex.calcArea();
var perimeter = rex.calcPerimeter();


#2

HI you forgot to close the constructo Rectangle

function Rectangle(height, width) { #open the Rectangle

#here put all the methods

} #close rectangle