Regex capture repeated groups
We have a following string:
And Question is: how we get the multiple groups of the same pattern.
With one group in the pattern, you can only get one exact result in that group. If your capture group gets repeated by the pattern (you used the + quantifier on the surrounding non-capturing group), only the last value that matches it gets stored.
Let see more about it.