Java examples for File Path IO:FileOutputStream
Assign standard in and out to InputStream and OutputStream
//from w w w. j a va 2 s . c o m import java.io.*; public class Main { public static void main(String[] args) { System.out.println("type:"); InputStream in = System.in; OutputStream out = System.out; try { int input = in.read(); System.out.println(input); out.write(input); out.close(); } catch(IOException e) { e.printStackTrace(); } } }