62,628
社区成员
发帖
与我相关
我的任务
分享package One;
import java.util.*;
import java.lang.*;
import javax.print.DocFlavor.STRING;
import java.io.*;
public class One {
public static void main(String[] args) {
// TODO Auto-generated method stub
Scanner input = new Scanner(System.in);
File file = new File("c:\\下载\\1.txt");
if (file.exists()) {
System.out.println("File already exists");
System.exit(0);
}
PrintWrite ouput = new PrintWrite("c:\\下载\\1.txt");
}
}
try {
PrintWriter ouput = new PrintWriter("c:\\下载\\1.txt");
} catch (FileNotFoundException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}

