import java.io.File;
import java.io.IOException;
public class MainClass{
public static void main(String[] argv){
File file = new File("c:\\test.dat");
String[] fileNames = file.list();
try {
System.out.println(file.createNewFile());
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
}
|