Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: Revealing difference in interpretation of 'number' between Perl and $other_language

by moritz (Cardinal)
on Sep 17, 2008 at 10:19 UTC ( #711949=note: print w/ replies, xml ) Need Help??


in reply to Revealing difference in interpretation of 'number' between Perl and $other_language

The Perl thinking is that a number is what looks like a number to a human being.

No, the Perl thinking is that if something is used a number, it is a number. When you call $a + $b (and they are not objects that overload +) then they are used as numbers, independently of what they look like. If there is no number representation, a default (0) is used, and optionally a warning emitted.


Comment on Re: Revealing difference in interpretation of 'number' between Perl and $other_language
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (8)
As of 2015-07-29 05:43 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (260 votes), past polls