Self Destructing program in C

This program will destroy itself upon execution. The program will cause the .exe file to be deleted upon execution. That is this program is capable of destroying itself upon execution. Here is the code

#include<stdio.h>
#include<conio.h>
#include<dos.h>
void main()
{
printf(“This program will destroy itself if u press any key!!!\n”);
getch();
remove(_argv[0]);/*array of pointers to command line arguments*/
}

People who read this also read:

  • No Related Posts
2 Comments
  1. July 26, 2011
    • August 14, 2012

Leave a Reply

Your email address will not be published. Required fields are marked *