import java.io.FileReader;
import java.io.IOException;
import java.io.FileNotFoundException;
/**
使用throw处理异常
*/
public class CheckException02 {
public static void main(String[] args) throws IOException {
readMyFile();
}
public static void readMyFile() throws IOException {
FileReader reader = null;
reader = new FileReader("d:/a.txt");
char c1 = (char)reader.read();
System.out.println(c1);
if(reader!=null) {
reader.close();
}
}
}