fix(learn): regex-criminal-in-hunt-challenge (#40901)
* fix: regex-criminal-in-hunt-challenge * Update curriculum/challenges/english/02-javascript-algorithms-and-data-structures/regular-expressions/find-one-or-more-criminals-in-a-hunt.md Co-authored-by: Randell Dawson <5313213+RandellDawson@users.noreply.github.com> Co-authored-by: Randell Dawson <5313213+RandellDawson@users.noreply.github.com>
This commit is contained in:
@ -48,12 +48,12 @@ Your regex should match two criminals (`CC`) in `"CC"`
|
||||
assert('CC'.match(reCriminals) && 'CC'.match(reCriminals)[0] == 'CC');
|
||||
```
|
||||
|
||||
Your regex should match three criminals (`CCC`) in `"P1P5P4CCCP2P6P3"`
|
||||
Your regex should match three criminals (`CCC`) in the string `P1P5P4CCCcP2P6P3`.
|
||||
|
||||
```js
|
||||
assert(
|
||||
'P1P5P4CCCP2P6P3'.match(reCriminals) &&
|
||||
'P1P5P4CCCP2P6P3'.match(reCriminals)[0] == 'CCC'
|
||||
'P1P5P4CCCcP2P6P3'.match(reCriminals) &&
|
||||
'P1P5P4CCCcP2P6P3'.match(reCriminals)[0] == 'CCC'
|
||||
);
|
||||
```
|
||||
|
||||
|
Reference in New Issue
Block a user