diff --git a/challenges/02-javascript-algorithms-and-data-structures/regular-expressions.json b/challenges/02-javascript-algorithms-and-data-structures/regular-expressions.json index 926d4ff64..5b681ec43 100644 --- a/challenges/02-javascript-algorithms-and-data-structures/regular-expressions.json +++ b/challenges/02-javascript-algorithms-and-data-structures/regular-expressions.json @@ -944,6 +944,10 @@ "text": "Your regex should find 6 non-alphanumeric characters in \"The five boxing wizards jump quickly.\".", "testString": "assert(\"The five boxing wizards jump quickly.\".match(nonAlphabetRegex).length == 6, 'Your regex should find 6 non-alphanumeric characters in \"The five boxing wizards jump quickly.\".');" }, + { + "text": "Your regex should use the shorthand character.", + "testString":"assert(/\\\\W/.test(nonAlphabetRegex.source), 'Your regex should use the shorthand character to match characters which are non-alphanumeric.');" + }, { "text": "Your regex should find 8 non-alphanumeric characters in \"Pack my box with five dozen liquor jugs.\"", "testString": "assert(\"Pack my box with five dozen liquor jugs.\".match(nonAlphabetRegex).length == 8, 'Your regex should find 8 non-alphanumeric characters in \"Pack my box with five dozen liquor jugs.\"');" @@ -1718,4 +1722,4 @@ } } ] -} \ No newline at end of file +}