Concatenating Strings Plus Equals Operator

Tell us what’s happening:
Describe your issue in detail here.
Hello could someone please help me out explaining what I have done wrong here, I feel like ive typed the code out correctly?

Your code so far


let myStr = "This is the first sentence.";
myStr += "This is the second sentence.";

Your browser information:

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/98.0.4758.141 Safari/537.36

Challenge: Concatenating Strings with the Plus Equals Operator

Link to the challenge:

Hi @Charlie88 !

Add this console.log to your code and you will see this output.

let myStr = "This is the first sentence.";
myStr += "This is the second sentence.";
console.log(myStr)

Screen Shot 2022-05-27 at 11.05.34 PM

Now compare your answer with the correct one

Thank you , something so silly can be so frustrating until you realise. :grinning:

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.