Error on Penguins, Properties, and the Prototype exercise!


This is how my code looks like:

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

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

and I'm getting SyntaxError: Unexpected token }

I can't seem to find my Error !! heeeeeeelllppp !!!

NEVER MIND I GOT IT !!! :smile:

Have a close look at

function Emperor(name}{