I am looking for regular expression to get the match as "HELLO"
and "WORLD"
separately when the input is any of the following:
"HELLO", "WORLD"
"HELL"O"", WORLD"
"HELL,O","WORLD"
I have tried few combination but none of them seem to work for all the scenarios.
I am looking to have my c# code perform something like this:
string pattern = Regex Pattern;
// input here could be any one of the strings given above
foreach (Match match in Regex.Matches(input, pattern))
{
// first iteration would give me Hello
// second iteration would give me World
}