Javascript: BugattiObject
The code has been modified slightly and now uploaded to the site.
Source is unknown.
BugattiObject.js
function Car(mk, md, h, z){
this.make = mk;
this.model = md;
this.hp = h;
this.zeroTo100 = z;
this.toString = function(){
return this.make + " " + this.model + " -> " + this.hp + "hp -> " + this.zeroTo100;
}
}
let myCar = new Car("Bugatti","Chiron",1479,"2.4sec");
console.log(myCar.toString());