My regular expression looks like this: "[a-zA-Z]+[ \t]*(?:,[ \t]*(\\d+)[ \t]*)*"
I can match the lines with this, but I don't know how to capture the numbers,I think it has to do something with grouping.
For example: from the string "asd , 5 ,2,6 ,8"
, how to capture the numbers 5 2 6 and 8?
A few more examples:
sdfs6df -> no capture
fdg4dfg, 5 -> capture 5
fhhh3 , 6,8 , 7 -> capture 6 8 and 7
asdasd1,4,2,7 -> capture 4 2 and 7
So I can continue my work with these numbers. Thanks in advance.