These machines generally include some type of system recovery media (such as: CD or DVD), or a recovery partition on your computer's hard drive. These system recovery options (media or partition) will restore your computer to the original state when you first bought it.
Warning: Be careful when using any of the system recovery options, its designed as an option of last resort. Make sure that you have backup of all your data, and original media for your applications that didn't come with the computer. Also make sure that you have product keys or serial numbers for installing these applications.Generally what happens when you use the system recovery option, your hard drive will be formated and the original system image from the factory will be installed. This image includes all the crapware that was originally installed when you bought your computer, and none of the latest patches or service packs
The first thing that you need to do after re-installing your operating system, is make sure your firewall is turned on. Install the latest system and application updates, then install your anti-virus and malware software. Then and only then should you install your applications, hardware drivers, other updates, or even attach your computer on the Internet.