How do I replace multiple spaces with no space in a word but preserving a single space between words in Java

后端 未结 0 1541
你的背包
你的背包 2020-12-22 20:09

Given string like "My na me is Joh nson". It should be changed to "My name is Johnson". How can we do this in Java? replaceAll(" ",&

相关标签:
回答
  • 消灭零回复
提交回复
热议问题