in reply to
Force currency view
There is no such thing as currency. You can format things nicely however:
printf('$%.2f', $number)
c:\>perl -e "printf('$%.2f', 12.9)" $12.90 > _
[download]
Comment on
Re: Force currency view
Select
or
Download
Code
Replies are listed 'Best First'.
Re^2: Force currency view
by
bart
(Canon)
on Feb 07, 2011 at 22:28 UTC
See also
sprintf
if you want to do something more with the result than just print it.
[reply]
In Section
Seekers of Perl Wisdom