+ 5
[Solved] Problem with regex match in javascript
In my prgram, there are 4 matches of given pattern, but it returns only 3, and when I break the last line to new line, it'll 4 matches. what is the reason and solution for this. https://code.sololearn.com/Wt2pnrzwfyR5/?ref=app
1 Answer
+ 3
Greedy and lazy quantifiers
https://javascript.info/regexp-greedy-and-lazy
It has the solution and the reason.
And the site overall is excellent Javascript reference
https://code.sololearn.com/WbA401yACUKa/#html