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! While you're at it, check out some resources Treehouse students have shared here.
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 trialFederico Lemaire
8,423 PointsparseInt() doubt
Hi there! I was looking for some more information in MDN about the parseInt function and I got dizzy. Why all this strings returns the number 15? parseInt('0xF', 16); parseInt('F', 16); parseInt('17', 8); parseInt(021, 8);
Or this ones returns the number 4? parseInt('0xF', 16); parseInt('F', 16); parseInt('17', 8); parseInt(021, 8);
Thank you for the time if somebody can explain it to me :)
1 Answer
<noob />
17,062 Pointsthis is a good article : https://developer.mozilla.org/he/docs/Web/JavaScript/Reference/Global_Objects/parseInt