Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re: How do I create/detect/handle Infinity?

by moritz (Cardinal)
on Jul 24, 2009 at 18:21 UTC ( [id://783074]=note: print w/replies, xml ) Need Help??


in reply to How do I create/detect/handle Infinity?

I think in Perl 5 this is platform specific, so I'll rather give the Perl 6 answer:
my $num = Inf; given $num { say "+Inf" when Inf; say "-Inf" when -Inf; say "NaN" when NaN; }

Works in Rakudo today.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (6)
As of 2024-03-28 22:48 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found