Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re^4: Number functions.. primes (ugly code runs faster)

by Discipulus (Canon)
on Apr 02, 2015 at 07:00 UTC ( [id://1122233]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
                 Rate primes_all         ch         jg    ch_opt2
    primes_all 1.75/s         --       -96%       -97%       -97%
    ...
    jg         51.9/s      2869%         4%         --        -8%
    ch_opt2    56.2/s      3117%        13%         8%         --
    
  2. or download this
    #! /usr/bin/perl
    use warnings;
    ...
    print'
            });
    ';
    
  3. or download this
    sub primes_opt_till_79 {
        my $n = shift;
    ...
        return @primes
    }
    
  4. or download this
                      Rate
    primes_original 74.2/s
    ...
    opt_till_83      192/s
    opt_till_79      193/s
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others examining the Monastery: (1)
As of 2024-04-19 00:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found