Basic JavaScript - Concatenating Strings with Plus Operator

it doesnt work. i have no idea why

var ourStr = “I come first.” + ‘I come second.’;

var myStr = ‘This is the start.’ + ’ This is the end.';

console.log(myStr)

var ourStr = "I come first." + 'I come second.';

var myStr = 'This is the start.' + ' This is the end.';
console.log(myStr)

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/108.0.0.0 Safari/537.36

Challenge: Basic JavaScript - Concatenating Strings with Plus Operator

Link to the challenge:

computers are very fussy about getting exact matches including with punctuation and white space

Please take a look at the console output when you run the test:

// running tests
myStr should be created using the const keyword.

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