#!/usr/bin/perl -w use strict; use warnings; open(IN, "<", "results_tblastn.csv"); while(my $row=){ chomp($row); my @line = split(/,/,$row); my $prot = $line[0]; my $scaff = $line[1]; my $start = $line[2]; my $end = $line[3]; print("\n\n working in $prot, $scaff \n"); system("./Programa_definitiu.pl $prot $scaff $start $end"); } close(IN);