int printf ( string format [, mixed argument [, mixed ...]] ) is the standard C way to format text
<? $animals = "lions, tigers, and bears"; printf("There were %s - oh my!", $animals); ?>
Maths: %d; English: %d; History: %d; Biology: %d.
and