⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 filein_out.java

📁 刘艺编著的java教程的课本习题加例题代码 很有用哦!
💻 JAVA
字号:
import java.io.*;
public class FileIn_Out{
  public static void main(String args[]){
   try{
    FileInputStream rf=new  FileInputStream("d:\\datafile\\file1.txt");
    FileOutputStream wf=new FileOutputStream("d:\\datafile\\file2.txt");
    byte b[]=new byte[512];
    while((rf.read(b,0,512))!=-1)
      wf.write(b);
    rf.close();
    wf.close();
   }
   catch(IOException ie){
    System.out.println(ie);
   }
   catch(Exception e){
    System.out.println(e);
   }
 }
}
    
  

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -