Task: JavaScript Replace All Occurrences of a Substring
Task: JavaScript Replace All Occurrences of a Substring: a task in Terminal-Lego-15k (Harbor dataset). In JavaScript, the String.prototype.replace() method, when called with a plain string as the first argument, only replaces the first occurrence of that string. For example:
The task
In JavaScript, the `String.prototype.replace()` method, when called with a plain string as the first argument, only replaces the **first** occurrence of that string. For example:
Part of PrimeIntellect/Terminal-Lego-15k.