I have many strings which have multiple spaces and one forward slash like this:
string a="xxxxxx xxx xxxxxxxx xxxxxx aaa/xxxxxxxxxxxxxxx";
or
string b="xxxx xxx xxxxxx bbbbb/xxxxxxx xxx";
or
string c="xx xx 12345/x xx"
What I need to do is to replace the substring "aaa" or "bbbbb" or "12345" (Please note that the substrings are just examples, they can be anything) with the new string I want.
The feature for the substring "aaa" or "bbbbb" or "12345" or anything is that the substring is right before the only one forward slash and right after the space in front of and closest to this slash.
How do I locate this substring so that I can replace it with the new substring I want? Thanks.