Ok so your hard drive got corrupted etc. so you put it aside until you could deal with it. You book a bar appointment and the blue shirt realizes a wipe and reinstall of the OS X will fix your mac he powers off the mac and reboots holding command plus R and gets to the restore partition of your hard drive ...so far so good.
He uses disk utility to wipe your hard drive , then closes it and throws you on the store Wifi and clicks reinstall OS X and it fails " unknown error"....oh boy this is going to be expensive , your politely told its the logic board and for a flat fee of 475 or 600.00 your out of warranty mac can be repaired good as new.
Here is the problem it is your logic board kind of , reloading your OS X requires logging into a server , if your system clock is wrong the server won't let you on ...sadly the console has no built in prompt to identify the issue so it comes back "unknown error" .....you can fix this issue in about three minutes free.
From restore menu top left icons click utilities then terminal and type date , most likely you will see December 2001 etc. clearly not right , here is the command line to fix the issue using the correct date and time in the following pattern , first two digits month second two digits date and next four time and last four year.
Hit enter and retype date , your system clock is now right , close terminal and click reinstall OS X and voila you can now reinstall OS X .....yeah it was your logic board but paying 475-600 to reset your system clock is a wee extreme for us .