In computer you use a hard drive to store all the data. In actual fact it is not the data alone that is stored in a hard drive, but even the software applications that you use in your system are installed in the hard drive. Before you could use a new hard drive, you need to make the hard drive ready for installing software and this is done with through formatting and partitioning the drive. By formatting you separate the drive into several partitions based on your requirements. You can either have one or multiple partitions in a hard drive. Then the drive is prepared for its first use. On the other hand, you may need to repartition or reformat the disk on many occasions such as
to add another operating system to the disk, you need to format the drive
in order to upgrade the operating system
to get rid of virus affected files
if the file system is corrupt
to speed up the pc
if you want to make the system ready for another user
Repartition or Reformatting of the hard disk drive will make all your previous data inaccessible. You will have to make sure that your data has a backup earlier than doing either of this. Though, in some cases like file system corruption or software failure can make a hard drive inaccessible. Thus you will be left with no alternative but to reformat the drive to make it functional again at the cost of your data. Even if, the data is inaccessible, you can still recover data from hard drive using specific formatted hard drive recovery software.