![](https://static.youtibao.com/asksite/comm/h5/images/m_q_title.png)
阅读下列程序,请写出该程的功能。import java.io.*;public class Class34{public static void
阅读下列程序,请写出该程的功能。
import java.io.*;
public class Class34
{
public static void main(String[] args)
{
File inputFile=new File("file1.txt");
File utputFile=new File("file2.txt");
int ch;
try
{
FileReader in=new FileReader(inputFile);
FileWriter ut=new FileWriter(outputFile);
while((ch=in.read())!=-1)out.write(ch);
in.close();out.close();
}
catch(FileNotFoundExceptione1)}
{System.out.println("文件没有找到!"+e1);}
catch(IOException e2)
{System.out.println("FilereadError!"+e2);}
}
}
![](https://static.youtibao.com/asksite/comm/h5/images/solist_ts.png)