Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re: sprintf() returning incorrect value

by pme (Prior)
on Jul 15, 2015 at 13:03 UTC ( #1134891=note: print w/replies, xml ) Need Help??


in reply to sprintf() returning incorrect value

Hi ppeel

Welcome to the monastery!

UPDATE: Sorry, I totally misread your problem.

You got what you described. If you need a single leading zero you can get this way:

$nfc_amt = "0$nfc_amt"; # or $nfc_amt = '0' . nfc_amt;

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1134891]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (6)
As of 2020-01-21 05:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Notices?