It all depends what output format you're using. Assuming we're talking about plain text, take a look at printf.
Update: Oops. Of course you're not talking about plain text. You're talking about an Excel spreadsheet. Ignore me and look at Spreadsheet::WriteExcel.
Thanks to ikegami for pointing out my insanity.
"The first rule of Perl club is you do not talk about Perl club." -- Chip Salzenberg
In reply to Re: Align numbers in a column to the right
by davorg
in thread Align numbers & text in a column to the right
by jinhuang1992
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |