Zero-padding with printf()
<? $zip = '6520'; $month = 2; $day = 6; $year = 2007; printf("ZIP is %05d and the date is %02d/%02d/%d", $zip, $month, $day, $year); ?>
Maths: %d; English: %d; History: %d; Biology: %d.
and