I have a string " 11:45 AM, 12:30 PM, 04:50 PM "
I wish to extract the first time from this string using java regex.
I have created a java regex like :
"\d*\S\d*\s(AM|PM)" for this.
However i can only match this pattern in Java rather than extract it. How can i extract the first token using the Regex i created