错误不是一点点了,改了一下,可以运行了import java.io.*;public class EnglishTeacher{
public static void main(String[]args) {
System.out.println("please Enter a letter:");//
try{
char c=(char)System.in.read();
switch(c){
case'c':
System.out.println("c is a cat");
break;
case'd':
System.out.println("d is a dog");
break;
default:
System.out.println("sorry,that,s all know");
break;
}
}catch(IOException e){
System.out.println("数据倒外处理");
}
}
}
public static void main(String[]args) {
System.out.println("please Enter a letter:");//
try{
char c=(char)System.in.read();
switch(c){
case'c':
System.out.println("c is a cat");
break;
case'd':
System.out.println("d is a dog");
break;
default:
System.out.println("sorry,that,s all know");
break;
}
}catch(IOException e){
System.out.println("数据倒外处理");
}
}
}
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货