in reply to Re: using flags
in thread using flags

the problem is that I need this variable outside of the loop too..... any other ideas?

Replies are listed 'Best First'.
Re: using flags
by Abigail-II (Bishop) on Oct 07, 2003 at 14:26 UTC
    If you need the variable, that's not a problem as using 'my $in_gene' just creates a different $in_gene for the loop. If you need the value, you'll have to use 2 variables, one to signal that there was a match somewhere (which is what $in_gene is doing right now), and one that signals a match at the current iteration. For that, a lexical variable will be perfect.

    Abigail