Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re: How to portably determine integer limits?

by jmcnamara (Monsignor)
on Oct 29, 2003 at 23:41 UTC ( [id://303147]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    
        #!/usr/bin/perl -wl
    ...
    
        print $Config{intsize};
    
  2. or download this
    
        use POSIX;
    ...
        print POSIX::INT_MIN; 
        print POSIX::UINT_MAX;
    
  3. or download this
        print 0.5 * (-1 + unpack "I", pack "I", -1);
        print 0.5 * (-1 - unpack "I", pack "I", -1);
        print             unpack "I", pack "I", -1 ;
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (6)
As of 2024-04-18 19:54 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found