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 trialAdam Fields
4,487 PointsFinally, add a # symbol and lastName in uppercase to the end of the userName string. The final value of userName is "231
I added the lastname to the id in concatenation I am lost could help
var id = "23188xtr";
var lastName = "Smith";
var userName = id.toUpperCase();
id += lastName"#";
<!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>
3 Answers
Rochell Hill
10,677 PointsFollow the instructions word for word...it seems tricky but it will make sense with some practice! (Basically just add a # and the lastName in uppercase to the end of the previous username to get the new username.)
last line should be:
userName = userName + '#' + lastName.toUpperCase();
Good luck!
Adam Fields
4,487 PointsI tried your response but it didn't pass I did exactly as posted and does not work maybe I missed something
Rochell Hill
10,677 PointsYour first 3 lines of code are correct, cut and paste the line of code I gave in the first answer and put it as the last line of code. It works. I just redid the challenge and it passes.