import java.io.File;
import java.io.IOException;
public class CreateFile {
public static void main(String[] args) throws IOException {
File file = new File("cpyFile2");
if (file.createNewFile())
System.out.println("文件创建成功!");
else
System.out.println("文件已存在!");
}
}