Consider that I have a following string:
string s = "hello a & b, <hello world >"
I want to replace "&"
(b/w a and b) with "&"
So, if I use
s.replace("&", "&");
It will also replace "&" associated with <
and >
.
Is there any way I can replace only "&" between a and b?