in reply to next unless - and then 'until'

Do you mean you want a condition that has to be met ONCE and then is "sticky"? Like:
my $keep_going = 0; while (my $job_B = readdir DIR_B) { print "D\n"; # ||= here means "assign to $keep_going if $keep_going is false" $keep_going ||= $job_B =~ /Out_$tag\.txt$/; next unless $keep_going; ... }

Jeff japhy Pinyan, P.L., P.M., P.O.D, X.S.: Perl, regex, and perl hacker
How can we ever be the sold short or the cheated, we who for every service have long ago been overpaid? ~~ Meister Eckhart

Replies are listed 'Best First'.
A reply falls below the community's threshold of quality. You may see it by logging in.