码迷,mamicode.com
首页 > 其他好文 > 详细

Test

时间:2017-09-03 22:13:14      阅读:145      评论:0      收藏:0      [点我收藏+]

标签:and   void   sys   readline   can   throw   another   while   public   


import java.io.*;
import java.util.Scanner;

public class ReadAndWriteTest {
    public static void main(String[] args) throws IOException {
        String filename = "C:\\Users\\Boyce\\IdeaProjects\\IdeaTest\\src\\com\\leewbl\\brains\\test.txt";
        BufferedReader br = breader(filename);
        String s = br.readLine();
        while(s!=null){
            System.out.print(s);
            s=br.readLine();
        }
        br.close();
        FileOutputStream out = writer(filename);
        out.write(filename.getBytes());
        out.close();
        System.out.println(System.in.read());
        copy("test.txt","copy.txt");
//        System.out.println(readInt("please input a int"));
//        System.out.println(readInt("another"));
    }
}

Test

标签:and   void   sys   readline   can   throw   another   while   public   

原文地址:http://www.cnblogs.com/leewbl/p/7471134.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!