For input text like “A.B.C.D. EFG”, I would like to get permutations of letters followed by dots to be converted to add space after the dot. So for the example above, I would like to get “A.B.C.D.”, “A. B.C.D.”, “A.B. C.D.”, “A.B.C. D.”, “A. B. C.D.”, “A.B. C. D.”, “A. B. C. D.”
Can this be done with regex ? If yes then any regex sample that works with c# (.net) would be most appreciated. The number of characters with dots is not known and can vary from text to text.
On a side note, if the text is “A. B. C. D. EFG” or “A. B.C.D. EFG” etc, I would like to get all permutations for that.
Regards
Something like
Then, to call it:-
It outputs:-
You just need to add the dots in, and check any other unspecified logic you may need (eg, stripping away the EFG’s from your example input.