62,074
社区成员
发帖
与我相关
我的任务
分享
string str = "总金额=金额+金额1+金额2+金额3";
string s1 = "金额";
string s2 = "8";
string result = Regex.Replace(str, @"\b" + s1 + @"\b", s2);
Console.WriteLine(result);