string str = " dd  d    d ";

str = str.Trim();

string s = Regex.Replace(str, " {2,}", " ");

即:s

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-03-10
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-12-11
  • 2021-05-23
  • 2021-10-22
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案