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 trialBryan Flanigan
2,617 PointsPlease help. I don't understand what this question is asking in the JS code.
This question is asking me to Assign an all uppcase version of the id variable to the userName variable
var id = "23188xtr";
var lastName = "Smith";
var userName
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JavaScript Basics</title>
</head>
<body>
<script src="app.js"></script>
</body>
</html>
2 Answers
LaToya Legemah
12,600 PointsWhat you need to do is declare the variable which is username. Then put that equal to the id variable. Then make that uppercase.
var userName= id.toUpperCase();
Extra info can be found here: http://www.w3schools.com/jsref/jsref_toUpperCase.asp
Steven Parker
231,248 PointsA string has already been assigned to the id variable.
There's a JavaScript function that converts text to uppercase. They want you to apply that function to id, and then put the result into userName.
Bryan Flanigan
2,617 PointsSteven, I understand that it's asking me to add the JS .toUpperCase but I don't really understand how to do it within this question. I'm looking for someone to help walk me through this code challenge question.
Bryan Flanigan
2,617 PointsBryan Flanigan
2,617 PointsGot it. Thanks.