in reply to Base sequence length in fasta format file

The translate operator with the same search and replace list will return a count of the number of matched characters. Read all about it in the perlop manpage.

while ($line = <INPUT>) { if ($line =~ tr/ACGT/ACGT/ > 250) { print $line; } }