Reuse Patterns Using Capture Groups_

Reuse Patterns Using Capture Groups_
0

#1

I could not pass the test. What is missing in my code? Thanks

Your code so far


let repeatNum = "42 42 42";
let reRegex = /(\d+\s)\1\d+/; // Change this line
let result = reRegex.test(repeatNum);

Your browser information:

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.106 Safari/537.36.

Link to the challenge:
https://learn.freecodecamp.org/javascript-algorithms-and-data-structures/regular-expressions/reuse-patterns-using-capture-groups


#2

Just answered a similar problem here: Reuse Patterns Using Capture Groups - Give me more examples please