freeCodeCamp
freeCodeCamp copied to clipboard
Hard coded values pass for Waypoint: Make Unique Objects by Passing Parameters to our Constructor
http://www.freecodecamp.com/challenges/waypoint-make-unique-objects-by-passing-parameters-to-our-constructor
Was helping someone out with this waypoint and they were able pass without passing the parameters to the object attributes. I tested it out and was able to pass with:
var Car = function(wheels, seats, engines) {
//Change this constructor
this.wheels = 3;
this.seats = 1;
this.engines = 2;
};
//Try it out here
var myCar = new Car(5,5,5);
// Only change code above this line
(function() {return JSON.stringify(myCar);})();
I will try to work on this one