JAVA
来源:互联网 发布:网络评选投票 编辑:程序博客网 时间:2024/06/03 19:47
vpackage liU11;
import java.io.BufferedReader;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;
public class LIU {
public static void main(String[] args) throws IOException {
new File("D:/HelloWorld.java");
FileReader fis=new FileReader("D:/HelloWorld.java");
int i;
while((i=fis.read())!=-1){
System.out.print((char)i);
}
fis.close();
FileReader fis1= null;
try {
fis1 = new FileReader("D:/HelloWorld.java");
} catch(FileNotFoundException e){
e.printStackTrace();
}
BufferedReader bf=new BufferedReader(fis1);
String s = null;
try{
while((s=bf.readLine())!=null){
System.out.println(s);
}
}catch ( IOException e){
e.printStackTrace();
}
}
}
import java.io.BufferedReader;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;
public class LIU {
public static void main(String[] args) throws IOException {
new File("D:/HelloWorld.java");
FileReader fis=new FileReader("D:/HelloWorld.java");
int i;
while((i=fis.read())!=-1){
System.out.print((char)i);
}
fis.close();
FileReader fis1= null;
try {
fis1 = new FileReader("D:/HelloWorld.java");
} catch(FileNotFoundException e){
e.printStackTrace();
}
BufferedReader bf=new BufferedReader(fis1);
String s = null;
try{
while((s=bf.readLine())!=null){
System.out.println(s);
}
}catch ( IOException e){
e.printStackTrace();
}
}
}
0 0
- java
- JAVA
- JAVA
- JAVA
- java
- Java
- Java
- JAVA:
- java
- java
- java
- java
- Java
- java
- java
- java
- JAVA?
- java
- JAVA
- ubuntu samba 性能优化和匿名访问
- makefile 中$@ $^ $<的意义
- 友元函数与友元类
- ios9 之后 配置百度地图出现的错误
- JAVA
- io流
- 禁止浏览器缓存- make sure web page is not cached
- 实现ListView的 分页加载,通过点击按钮实现
- HDU 4252A Famous City
- 删除字符串中连续字符
- leetcode刷题,总结,记录,备忘 283
- Effective C++ —— 别让异常逃离析构函数
- Struts、hibernate、Spring 官网下载步骤