Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community!
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.Start your free trial
What am I doing wrong?!?
var numWidth = parseInt("640px", 10);
and it says that is wrong. I've typed different variations of this.
var numWidth = parseInt("640", 10); var numWidth = parseInt("boxWidth", 10);
what am I doing wrong?
kevin jordan11,353 Points
Hey Erik -
Super close I think. All you need is to remove the parenthesizes around boxWidth in your parseInt call:
var numWidth = parseInt("640", 10); => should be parseInt(boxWidth, 10);
William LiCourses Plus Student 26,868 Points
you should pass in boxWidth as argument, not the number.
var numWidth = parseInt(boxWidth, 10);