From 80d66a98089f246483d0218d0f068b4e26db4116 Mon Sep 17 00:00:00 2001 From: Aashis kumar Date: Sun, 17 Feb 2019 22:14:19 +0530 Subject: [PATCH] Update check-for-all-or-none.english.md (#34758) Added Solution to the problem Change the regex favRegex to match both the American English (favorite) and the British English (favourite) version of the word. --- .../regular-expressions/check-for-all-or-none.english.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/curriculum/challenges/english/02-javascript-algorithms-and-data-structures/regular-expressions/check-for-all-or-none.english.md b/curriculum/challenges/english/02-javascript-algorithms-and-data-structures/regular-expressions/check-for-all-or-none.english.md index 01e404e09e..52fc1e7dc6 100644 --- a/curriculum/challenges/english/02-javascript-algorithms-and-data-structures/regular-expressions/check-for-all-or-none.english.md +++ b/curriculum/challenges/english/02-javascript-algorithms-and-data-structures/regular-expressions/check-for-all-or-none.english.md @@ -56,6 +56,8 @@ let result = favRegex.test(favWord);
```js -// solution required +let favWord = "favorite"; +let favRegex = /favou?r/; +let result = favRegex.test(favWord); ```