Tell us what’s happening:
Describe your issue in detail here.
So simply from left to right, can someone explain to me how this works/passes? In particular, I do not understand why the “^” or “$” are necessary. Also, just to understand capture groups, is the “\1” (used twice) indicating we want the first capture group to repeat two more times (a total of 3 times) in this example?
Your code so far
let repeatNum = "42 42 42";
let reRegex = /^(\d+) \1 \1$/; // Change this line
let result = reRegex.test(repeatNum);
Your browser information:
User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/119.0.0.0 Safari/537.36
Challenge Information:
Regular Expressions - Reuse Patterns Using Capture Groups