Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much

Re: Perl 5 numeric type and simplifications

by BillKSmith (Monsignor)
on May 06, 2021 at 03:55 UTC ( #11132120=note: print w/replies, xml ) Need Help??

in reply to Perl 5 numeric type and simplifications

The choice between print and printf depends on how badly you 'rely' on the format. The former usually does what you want with less effort. It may even be better for a special case that you forgot about. An occasional 'long number' may be annoying, but does no real harm if you are calculating the next move in your fantasy football game. In another application, the same behavior could spoil a whole batch of expensive forms (or worse). Clearly the latter is called for. They each have advantages. It is part of a Perl programmer's job to choose appropriately for each application.
  • Comment on Re: Perl 5 numeric type and simplifications

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (3)
As of 2022-05-18 13:12 GMT
Find Nodes?
    Voting Booth?
    Do you prefer to work remotely?

    Results (70 votes). Check out past polls.