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

Re^2: Get random unique lines from file

by roboticus (Chancellor)
on Aug 17, 2012 at 23:42 UTC ( #988126=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    $ for J in {0,1,2,3,4,5,6,7,8,9}{0,1,2,3,4,5,6,7,8,9}{0,1,2,3,4,5,6,7,
    +8,9}; do ./pm_sample_lines_from_file.pl a_million_lines 25 >t.$J; don
    +e
    
  2. or download this
    #!/usr/bin/perl                                                       
    +                                        
    #
    ...
        }
        printf "% 3u: (% 3u) %s\n", $I, $H{$I} // 0, $bar;
    }
    
  3. or download this
    $ ./pm_sample_histo_test.pl t.*
      0: (321) **************************************************
    ...
     97: (263) **************************************+*          
     98: (241) *************************************             
     99: (236) ************************************    
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://988126]
help
Chatterbox?
erix .oO( apparently but does not GotToBFast )
[Discipulus]: now i must come back to my house/hoven monks: dont do interesting discussion in my absence!
[erix]: or apparently, now it does :)
[GotToBTru]: heh
erix prods ambrus to (re-)start cbstream...
[GotToBTru]: I've got a program with an if ... or ... statement with 80 clauses
[stevieb]: 80 clauses? dispatch table?
[GotToBTru]: no, lookup

How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (13)
As of 2017-06-22 12:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    How many monitors do you use while coding?















    Results (519 votes). Check out past polls.