我是 Java 新手...是否有与 C# 中的 ReadKey() 类似的方法来避免控制台应用程序关闭?
thanks
您还可以使用System.in.read(),如果您同意仅使用“Enter”键作为退出键。
System.in.read()