public class MyFile implements Runnable{
public void run(){
while (true){
try{
FileReader fr=new FileReader(new File("a.txt")) ;
String line=fr.readLine();
System.out.println(line);
}catch(IOException err) {
}
sleep(1000);
}
}
}
A、a.txt路径不对
B、sleep(1000)需要用Thread.sleep(1000);
C、没有关闭FileReader
D、死循环,没有退出的可能
E、fr.readLine()没有这个方法
BCDE