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 trialCarl Mclamb
Full Stack JavaScript Techdegree Student 3,516 Pointshow to convert uppercase
I have no idea what to do next. How do I change the role variable in the string for msg to all capital. Thank you!
let firstName = "Carl";
let lastName = "Mclamb";
let role = 'developer';
let msg = firstName + " " + lastName + ":" + role.toUpperCase() + ".";
3 Answers
Blake Runyon
Full Stack JavaScript Techdegree Student 7,539 PointsHey Dude,
I think the problem you're having is more simple than you're thinking. If you re-read the challenge, they're looking for:
Carl Mclamb: DEVELOPER
You've written it as:
Carl Mclamb:DEVELOPER.
let firstName = 'Blake';
let lastName = 'Runyon';
let role = 'developer';
let msg = firstName + " " + lastName + ": " + role.toUpperCase();
I'm also new to JavaScript. One thing I've learned is to make sure you don't get tunnel vision on the complex problems and miss out on simple mistakes. Normally, for me at least, I make many simple mistakes haha. Good coding!
Carl Mclamb
Full Stack JavaScript Techdegree Student 3,516 PointsThanks man. Sorry it took me a while to reply
Leonel Adames
768 Pointsin order to convert the string 'role' into uppercase you need to use, console.log( role.toUpperCase() ); on the following line, which is line 5. the same is true for lower case, console.log( role.toLowerCase() );
Carl Mclamb
Full Stack JavaScript Techdegree Student 3,516 PointsCarl Mclamb
Full Stack JavaScript Techdegree Student 3,516 PointsThanks man!