Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

my versus our, why is my slower when script ends (global cleanup)

by marioroy (Prior)
on Apr 22, 2017 at 01:51 UTC ( [id://1188596]=perlquestion: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    use strict;
    use warnings;
    ...
    my %barcode_hash = map { $_ => $data } 1 .. $size;
    print "end\n";
    
  2. or download this
    ...
    our %barcode_hash = map { $_ => $data } 1 .. $size;
    ...
    
  3. or download this
    use strict;
    use warnings;
    ...
    
    printf "%0.03f seconds\n", time - $start_time;
    
  4. or download this
    perl timeit.pl perl test.pl
    
    my  %big_hash:  2.726 seconds
    our %big_hash:  1.351 seconds
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (6)
As of 2024-04-23 13:38 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found