Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

JavaScript JavaScript Basics Working with Strings Combine and Manipulate Strings

Tareq Ghulam
Tareq Ghulam
573 Points

Hi I do not understand why I am getting error here

I am able have ths work on local but not on this challnge , am I doing something wrong

app.js
let firstName =('tareq');
let lastName = ('ghulam');
let role = 'developer';
msg = (firstName)+('')+(lastName)+(':')+('')(role)+('.');

1 Answer

Rick Gleitz
Rick Gleitz
45,207 Points

Hi Tareq,

Just a few simple things that I see here. 1) You don't need the period at the end. I'm not sure if that actually causes a problem with passing, though. 2) There needs to be an actual space inside the quote marks for the spaces. You just have two quote marks side-by-side. 3) There needs to be a plus sign to concatenate the last space with the word role. Additionally, you can combine the colon and the space between lastName and role rather than concatenating twice. Hope this helps!