All pastes #404762 Raw Edit

Someone

public text v1 · immutable
·published 2007-03-21 06:37 UTC
rendered paste body
#!/usr/bin/perl

     #first create an array of all the letters
     @letters = ("a".."z");
     #Create your four letter words
     for(my $i=0; $i<1000; $i++){
     my $key = $letters[rand(26)] . $letters[rand(26)] . $letters[rand(26)] . $letters[rand(26)];
    #print $key . "\n";
     $wordlist[$i]=$key;
}
open(outfile, ">/perlprograms/wordlist.txt");
print outfile "Word | Position"."\n"."----|--------"."\n";
    for(my $y=0; $y<10000; $y++){
     print outfile $wordlist[rand($#wordlist)]. " (".$y .")" ."\n";
}
close(outfile);