in reply to performance issues

Yeah, your regex is pretty bad, and in this simple case you don't even need a regex.
my @array; my $match = 'some_criteria'; while (<FH>) { chomp; # thanks gwadej for reminding me my ($x,$y) = split /\t/, $_; if ( $x eq $match ){ push @array, $y; } } print "@array\n";

I'm not really a human, but I play one on earth Remember How Lucky You Are

Replies are listed 'Best First'.
Re^2: performance issues
by gwadej (Chaplain) on Jan 27, 2009 at 19:00 UTC

    You might want to add a chomp before the split.

    G. Wade
Re^2: performance issues
by perlcat (Novice) on Jan 27, 2009 at 19:05 UTC
    thanks, that's indeed a neat way to do it!