public class re
{
public static void main(String args[]) throws IOException
{
Integer ch;
ch=System.in.read();
System.out.println("Just input:"+ch);
}
}

解决方案 »

  1.   

    这个调什么啊,你输入的字符,然后回车,会返回他的ascii码。例如 你输入1,在这里并不是返回数字1,而是一个字符'1',ascii里面的代码是49,所以这里会显示Just input: 49   如果你输入其他的字符串例如 dfdfdfdfdf,他会返回第一个字符d的ascii码Just input: 100
      

  2.   

    除了没有import java.io.IOException;之外,程序无错