en.javascript.info/10-regular-expressions-javascript/12-regexp-anchors/1-start-end/solution.md
Ilya Kantor 7ddea43ab4 up
2017-03-20 20:52:29 +03:00

6 lines
327 B
Markdown

The empty string is the only match: it starts and immediately finishes.
The task once again demonstrates that anchors are not characters, but tests.
The string is empty `""`. The engine first matches the `pattern:^` (input start), yes it's there, and then immediately the end `pattern:$`, it's here too. So there's a match.