Sounds like a job for format! Take a look at 'perldoc perlform' for examples and use.
But, first take a peek at printf() or sprintf(). But, formats are good to read about anyways ;)
Cheers,
KM
Comment on RE: Decimal alignment and loss of zero at print?