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 trialErica Queen
2,863 Pointswhen answering task 2, I get a message stating task 1 is no longer correct. Could you check my answers?
I have attempted everything I can think of. I would like some assistance, if possible. Also, the "preview" screen is not allowing me to view a preview of the answer.
name = "John"
subject = "Treehouse loves" += name
1 Answer
Steven Parker
231,248 PointsThe message might be a bit misleading.
Clearly, you didn't change your task 1 code, but a syntax error in the additional code made the entire file look bad.
The normal concatenation operator is just "+
". The "+=
" is a special kind of assignment operator, and would not be used in combination with a normal assignment.
Also remember to provide an extra space with your literal string to separate it from the one it is being concatenated with.