yeah,
1)plug cd or usb with new os
2)start the mac holding option key, for enter in boot menu.
3)when instal procedure is ready, go on utility on the top menu, there you will find utility disk for format the new drive....(i hope its ssd :))
good luck!