import java.io.*;
class test6 {
public static void main(String args[])throws Exception {
int data;
while((data=System.in.read())!=-1)
{
System.out.println(data);
}
}
}
为什么输入:1
输出:
49
13
10
本文详细解析了一个使用Java实现的简单输入输出程序,通过实例展示了如何读取并打印输入的数据。
import java.io.*;
class test6 {
public static void main(String args[])throws Exception {
int data;
while((data=System.in.read())!=-1)
{
System.out.println(data);
}
}
}
为什么输入:1
输出:
49
13
10
1814
8338

被折叠的 条评论
为什么被折叠?