You can buy a foreclosed property in two ways: at an auction or from a bank. While you may be able to get a better deal at a courthouse auction, the process is riskier. For one thing, you won't be able to go into the home and look around or inspect it before buying. Also, if you purchase the property at an auction, you -- that's right, you, the homeowner -- may have to evict the current residents, which is extremely unpleasant for everyone involved. If you're up for the risks of an auction, however, make sure to do your research beforehand to find out whether you're getting a good deal, and don't be bullied into making a bid you don't want to make or can't afford.
Buying from a bank is less risky. You'll get to examine the property before purchasing, and the bank may have done some repairs or updated the home since repossessing it. Plus, they'll be no one currently living there that you'll have to kick out, which is a major plus.