From 6a61c04fc51d7a0389ac4c55784eee9ddb7ca25a Mon Sep 17 00:00:00 2001 From: Vse Mozhe Buty Date: Mon, 7 Dec 2020 22:54:54 +0200 Subject: [PATCH] Fix confusing wording in 9.6 (Word boundary: \b) `\bHello\b` pattern was just analyzed in the previous paragraph, so the current wording is a bit confusing. --- 9-regular-expressions/06-regexp-boundary/article.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/9-regular-expressions/06-regexp-boundary/article.md b/9-regular-expressions/06-regexp-boundary/article.md index 7c9f442f..06b5ac9f 100644 --- a/9-regular-expressions/06-regexp-boundary/article.md +++ b/9-regular-expressions/06-regexp-boundary/article.md @@ -27,7 +27,7 @@ So, it matches the pattern `pattern:\bHello\b`, because: 2. Then matches the word `pattern:Hello`. 3. Then the test `pattern:\b` matches again, as we're between `subject:o` and a comma. -The pattern `pattern:\bHello\b` would also match. But not `pattern:\bHell\b` (because there's no word boundary after `l`) and not `Java!\b` (because the exclamation sign is not a wordly character `pattern:\w`, so there's no word boundary after it). +So the pattern `pattern:\bHello\b` would match, but not `pattern:\bHell\b` (because there's no word boundary after `l`) and not `Java!\b` (because the exclamation sign is not a wordly character `pattern:\w`, so there's no word boundary after it). ```js run alert( "Hello, Java!".match(/\bHello\b/) ); // Hello