Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses

Re: Re^4: The Definitive Unit Conversion Script

by BrowserUk (Pope)
on Dec 13, 2002 at 21:11 UTC ( #219752=note: print w/replies, xml ) Need Help??

in reply to Re^4: The Definitive Unit Conversion Script
in thread The Definitive Unit Conversion Script

You don't have to specify the units on input. If you supply a number (or array of numbers), then they just get converted to numbers.

The idea was that of you were reading stuff from another source with the units specified, then the direction of the conversion would be determined for you. Just a thought.

Also, if you don't specify the units at declaration time, units are not even looked for. If they are supplied at runtime, its just results in a runtime "non-numeric" error. I'll look at your code now ;^).

Examine what is said, not who speaks.

  • Comment on Re: Re^4: The Definitive Unit Conversion Script

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (2)
As of 2021-04-21 05:11 GMT
Find Nodes?
    Voting Booth?

    No recent polls found