Concatenating Strings with the Plus Equals Operator

Concatenating Strings with the Plus Equals Operator
0

#1
// Example
var ourStr = "I come first. ";
ourStr += "I come second.";

// Only change code below this line

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

cant figure out where im wrong hel


#2

myStr should have a value of “This is the start. This is the end.”

Notice the “space” after the period?


#3

I cleaned up your code.
You need to use triple backticks to post code to the forum.
See this post for details.


#4

here it is help you:

[details=spoilers]```
var myStr = "This is the first sentence. ";
myStr += “This is the second sentence”;


#5

Please don’t provide solutions in the forum without hiding them, especially when the original poster hasn’t asked for one.


#6

ok, I 'll remember. thanks