/****************************************************************************** * This program simply copies an input stream to the console character by * character like the Unix 'cat' program. * * Copyright © 2020 Richard Lesh. All rights reserved. *****************************************************************************/ import org.pureprogrammer.Utils; public class StreamIO1 { public static void main(String[] args) { int c; while ((c = Utils.getchar()) != -1) { System.out.print(String.valueOf(Character.toChars(c))); } } }