Self destroying java program.

Code:
import java.io.File;
 
public class SelfDestruct {
    public static void main(String argz[]) {
        File file=new File("SelfDestruct.class");
        file.delete();
        return;
    }
}

Output:
$ ls -l SelfDestruct.class 
-rw-rw-r-- 1 tom tom 393 Mar  7 16:25 SelfDestruct.class

$ java SelfDestruct

$ ls -l SelfDestruct.class 
ls: cannot access SelfDestruct.class: No such file or directory