输入流,fileInputstream ,

输入流:

package com.fanjia.day20200803;

import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.IOException;

public class Demo07 {
	public static void main(String[] args) throws IOException {
		//FileInputStream fis = new FileInputStream(new File("a.txt"));
		FileInputStream fis = new FileInputStream("a.txt");
		/*int a = fis.read();
		System.out.println(a);*/
		
		while(fis.read() != -1){
			System.out.println(fis.read());
		}
		
		
		
	}

}
©️2020 CSDN 皮肤主题: 1024 设计师:上身试试 返回首页