This forum is now read-only. Please use our new forums at discuss.codecademy.com.

Animate Your Name Forum

View Course » View Exercise

116 points
A0805e07e2336fd2df22118856fb9650?s=140&d=retro
Submitted by
mykil-paul
about 3 years ago

10/15 [resolved] Make sure you have defined all the variables!

Please tell me what is wrong here.
var red = [0, 100, 63];
var orange = [40, 100, 60];
var green = [75, 100, 40];
var blue = [196, 77, 55];
var purple = [280, 50, 60];

var myName = ["Gabe","MONKEY","OoOoOoO];
letterColors =["red","orange","green","blue","purple"];

drawName(myName, letterColors; ["blue","red","orange"]);


1 vote

permalink

Hi mykil-paul,

You will need to make your myName variable a string, not an array. So no [ ] brackets. One set of " ". Instead of this:

var myName = ["Gabe","MONKEY","OoOoOoO];

something more like:

var myName = "Gabe MONKEY OoOoOoO";

Your letterColors array should be an array of variables that represent colors, not an array of strings. This:

letterColors =["red","orange","green","blue","purple"];

should be like this:

letterColors = [red, orange, green, blue, purple];

Your drawName function call takes two arguments, myName and letterColors. Instead of:

drawName(myName, letterColors; ["blue","red","orange"]);

you should have this:

drawName(myName, letterColors);

3691 points
55df2afa95e3787b9200005e_359368177
Submitted by
Judy
about 3 years ago


0 votes

permalink

Hi mykil-paul, I see that you now have a working Animate Your Name codebit so I have marked your question as [resolved] - It looks great!

3691 points
55df2afa95e3787b9200005e_359368177
Submitted by
Judy
about 3 years ago