in reply to begginer help running perl script

There is nothing in this script that allows you to redirect the output to a different file every 5000 lines. There are no switches or options for Perl to do that.

You can of course redirect the output to a file from the command-line

perl split_FASTA-no_overlap.pl "filename" > output.file

Or you can "pipe" the output of this program to the input of another Perl program which then saves the data in a file and starts a new file every 5000 lines:

perl split_FASTA-no_overlap.pl "filename" | perl splitter.pl -L5000

CountZero

A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James

My blog: Imperial Deltronics