If you wish to create a computer virus, make sure it's not going to get you in legal trouble. If you are good there, you need to open notepad and input a string of coding that will tell the computer how to behave. You can find numerous codes available for this online. When you have it put in notepad, save it. Then when someone opens it, it will attack!