Slash Boxes
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
More | Login | Reply
Loading... please wait.
  • by Juerd (1796) on 2004.10.14 7:21 (#35184) Homepage
    use File::Slurp qw(read_file);
    my @words = read_file '/usr/share/dict/words';
    chomp @words;
    my $regex = join '|', map quotemeta, @words;
    $regex = qr/$regex/;
    • OK, that was a good answer... what I forgot to say was: I don't know the language nor do I have a list of its words :-)

      I'm doing this for something like fifteen different languages.