String.prototype.concatintermediateconst str = 'Hello'
str.concat(', ', 'World', '!') // β 'Hello, World!'
''.concat('a', 'b', 'c') // β 'abc'Use concat() to join two or more strings together, returning a new string without modifying the originals.
.concat() never modifies the original string. Strings in JavaScript are immutable.
Challenge: Implement concatAndCheck(a, b) that returns an object { result, originalUnchanged } where result = a.concat(b) and originalUnchanged is true if a is still its original value.
concatAndCheck('foo', 'bar') // β { result: 'foobar', originalUnchanged: true }