import java.io.File;
import java.io.IOException;
public class Test02 {
public static void main(String[] args) {
// TODO Auto-generated method stub
File dir = new File("D:/a/b/c");
if(!dir.exists()) {
dir.mkdirs();
}
File file = new File("D:/a/b/c/haha.xls");
try {
System.out.println(file.createNewFile());
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
try {
Thread.sleep(10*1000);
} catch (InterruptedException e) {
e.printStackTrace();
}
file.delete();
}
}