Can't find the error in my code


Error message pops up saying "It looks like you didn't set up Emperor to inherit from Penguin!", but I can't find my error

function Penguin(name) { = name;
    this.numLegs = 2;

// create your Emperor class here and make it inherit from Penguin
function Emperor(name) { = name;
Emporer.prototype = new Penguin();
// create an "emperor" object and print the number of legs it has
    var emporer = new Emporer("Stan");


if you did it right the check your spelling. look at what you have written versus what the error msg is telling you


Hahah thanks rydan. problem solved.


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.