Be aware that doing so will completely erase EVERYTHING on your computer. All pictures saved, all videos, all programs downloaded, etc.
Generally, when you put in an oem or a retail version of windows, it will boot up (may say to press any key to boot from cd, do so), ask you if you want to install, where you want to install, and somewhere it will give you the option to completely format the partition. If you use an upgrade version, I'm not sure if it'd be bootable (you could use the tutorial on this site to make it bootable, but you'd need a prior version of windows to use to prove you're eligible to use the upgrade version).
Also note, that many OEM providers (Dell, HP, Compaq, etc.) have a restore CD. This should also completely wipe out your drive, and put the hard drive back to its original state.
Again, be aware that this will delete EVERYTHING on your hard drive. Please don't come back here asking how you can unformat your drive to get all those baby pictures back, or what-not. You can't (actually, you might be able to, if that data hasn't been overwritten, but it's not guaranteed and will cost anywhere from $$ to $$$$ or more).