Skip to content

Commit 0261aa9

Browse files
lex111oshliaer
andauthored
Update 9-regular-expressions/03-regexp-character-classes/article.md
Co-Authored-By: oshliaer <oshli.a.er@gmail.com>
1 parent af4a589 commit 0261aa9

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • 9-regular-expressions/03-regexp-character-classes

9-regular-expressions/03-regexp-character-classes/article.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ alert( str.replace(/\D/g, "") ); // 79031234567
174174
Давайте попробуем найти цифры, разделенные тире:
175175

176176
```js run
177-
alert( "1 - 5".match(/\d-\d/) ); // null, нет совпадений!
177+
alert( "1 - 5".match(/\d-\d/) ); // null, нет совпадения!
178178
```
179179

180180
Здесь мы исправляем это, добавляя пробелы в регулярное выражение `pattern:\d - \d`:

0 commit comments

Comments
 (0)