How to check whether a hard disk is free of bad sectors?

I bought a 20 gb hard disk from my friend. I want to check whether the hard disk is free of bad sectors.
please help
9 answers 9