@@ -0,0 +1,2234 @@
+import java.io.*;%0Apublic class filereader %7B%0A   public static void main (String%5B%5D args) %7B%0A      String p_f = null;%0A      String p_n = null;%0A      String p_c = null;%0A      String SUFFIX = %22.out%22;%0A      int i = 0;%0A      while (i %3C args.length ) %7B%0A         // Process -f%0A         if ( args%5Bi%5D.compareTo(%22-f%22) == 0 ) %7B%0A            i++;%0A            if ( i %3C args.length ) %7B%0A                p_f=args%5Bi%5D;%0A            %7D else %7B%0A                System.out.println(%22No file name specified%22);%0A                System.exit(-1);%0A            %7D%0A         %7D%0A         // Process -n%0A         if ( args%5Bi%5D.compareTo(%22-n%22) == 0 ) %7B%0A            i++;%0A            if ( i %3C args.length ) %7B%0A               p_n=args%5Bi%5D;%0A            %7D else %7B%0A               System.out.println(%22No new name specified%22);%0A               System.exit(-1);%0A            %7D%0A         %7D%0A         // Process -c%0A         if ( args%5Bi%5D.compareTo(%22-c%22) == 0 ) %7B%0A            i++;%0A            if ( i %3C args.length ) %7B%0A               p_c=args%5Bi%5D;%0A            %7D else %7B%0A               System.out.println(%22No name to change specified%22);%0A               System.exit(-1);%0A            %7D%0A         %7D%0A         i++;%0A      %7D%0A      if ( p_f == null ) %7B%0A         System.out.println(%22No file name specified%22);%0A         System.exit(-1);%0A      %7D%0A      if ( p_n == null) %7B%0A         System.out.println(%22No new name specified%22);%0A         System.exit(-1);%0A      %7D%0A      if ( p_c == null) %7B%0A         System.out.println(%22No name to change specified%22);%0A         System.exit(-1);%0A      %7D%0A      File infile = new File(p_f);%0A      if ( ! infile.exists() ) %7B%0A         System.out.println(%22File %22 + p_f + %22 not found%22);%0A         System.exit(-1);%0A      %7D%0A      try %7B%0A         FileReader ifile = new FileReader(p_f);%0A         FileWriter ofile = new FileWriter(p_f + SUFFIX);%0A         BufferedReader buffer = new BufferedReader(ifile);%0A         BufferedWriter obuffer = new BufferedWriter(ofile);%0A         String line = %22%22;%0A         while (( line = buffer.readLine() ) != null )%7B%0A            obuffer.write(line.replaceAll(p_c,p_n));%0A            obuffer.newLine();%0A         %7D%0A         buffer.close();%0A         obuffer.close();%0A      %7D%0A      catch ( IOException e) %7B%0A         System.out.println(%22A file error occured%22);%0A      %7D%0A   %7D%0A%7D%0A%0A

Create filereader.java