I’m asking this question for interest.
Is it possible to somehow alter this expression so that instead of (Franklin|Eleanor), you can substitute any combination of letters?
let myString = "Eleanor Roosevelt";
let myRegex = /(Franklin|Eleanor).*Roosevelt/; // Change this line
let result = myRegex.test(myString); // Change this line
// After passing the challenge experiment with myString and see how the grouping works
Challenge: Check For Mixed Grouping of Characters
Link to the challenge: