xxxxxxxxxx
// a regular expression with two non-capturing groups
// and one capturing group
const regex = /(?:Jane|John|Alison)\s(.*?)\s(?:Smith|Smuth)/;
const result = regex.exec('Jane Isabell Smith');
console.log(result[0]); // 'Jane Isabell Smith'
console.log(result[1]); // 'Isabell'
const notMatchingResult = regex.exec('nope');
console.log(notMatchingResult); // null