Why strings are immutable
Once created, a string's characters cannot change. This lets JavaScript cache length and hash, making strings fast as object keys and safe to share. Every operation that looks like 'editing' actually allocates a new string:
let s = "cat";
s = s + "dog"; // new object, old 'cat' may be garbage collected
For building many pieces, accumulate in a list and call Array.join('') once, repeated + on large strings is O(n²).
Template literals and escaping
Backtick strings let you interpolate ${...} and span multiple lines:
const name = "Ada";
const greeting = `Hello, ${name}!`;
const block = `line 1
line 2`;
Inside ${} you can put any expression, including a function call. To print a literal backtick or ${, escape it with a backslash: \\` or \${`.