I can use one common regex pattern to grab groups from the following two strings
show me light not fear
show me light and grace
Regex: show me ([\w]+) (not ([\w]+)|and ([\w]+))
But I cannot find a common regex for below:
show me light
show me light and grace
Regex: show me ([\w]+)| and ([\w]+)
it treats "and grace" in second string as separate match, Can you please help me identify the mistake