提供的是一种思路,和具体语言无关。

string test = "good good study day day up";
string r = test.Replace("oo","");
int num = (test.Length - r.Length) /"oo".length; 
Console.WriteLine(num);

  

相关文章:

  • 2021-07-12
  • 2022-12-23
  • 2022-12-23
  • 2021-12-16
  • 2022-12-23
  • 2021-11-22
  • 2021-11-15
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-12-12
  • 2022-02-16
  • 2022-03-09
  • 2021-10-26
  • 2022-01-25
相关资源
相似解决方案