import java.io.*; class jConcatFiles { public static void main(String args[]) { try { FileInputStream file1=null; FileInputStream file2=null; SequenceInputStream file3=null; file1=new FileInputStream("City.txt"); file2=new FileInputStream("Output.txt"); file3=new SequenceInputStream(file1,file2); BufferedInputStream inBuffer=new BufferedInputStream(file3); BufferedOutputStream outBuffer=new BufferedOutputStream(System.out); int ch; while((ch=inBuffer.read())!=-1) { outBuffer.write((char)ch); } }catch(Exception e){} } }