Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

"Just use a hash": An overworked mantra?

by davido (Cardinal)
on Nov 16, 2011 at 20:02 UTC ( [id://938456]=perlmeditation: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    sub count_in_hash {
        my $num_ints = $_[0] // $datasize;
    ...
            for( 1 .. $num_ints );
        return \%container;
    }
    
  2. or download this
    sub count_in_array {
        my $num_ints = $_[0] // $datasize;
    ...
            } 1 .. $#container
        };
    }
    
  3. or download this
    int rand_ranged_value ( int min, int max )
    {
    ...
        Safefree( int_sieve );
        Inline_Stack_Done;
    }
    
  4. or download this
    #!/usr/bin/env perl
    
    ...
        Inline_Stack_Done;
    }
    
  5. or download this
    ok 1 - hash_count(): Correct key count in RV.
    ok 2 - hash_count(): Correct value count in RV.
    ...
    hash_count    22.8          --        -45%        -92%
    array_count   12.4         83%          --        -85%
    c_aray_cnt    1.91       1093%        551%          --
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlmeditation [id://938456]
Approved by Corion
Front-paged by MidLifeXis
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others scrutinizing the Monastery: (5)
As of 2024-03-29 08:51 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found