Re: State Variables

2002-09-30 Thread Robin Cragg
Here's a simple version... $a = 5; while ($a) { foreach (1..10) { if ($_ == $a) { $exit++; } } last if ($exit); } print "\$a is $a\n"; R At 20:20 27/09/2002 -0700, Michael Kelly wrote: >On Fri, Sep 27, 2002 at 08:29:53PM -0500, Grant Hansen wrote:

Re: State Variables

2002-09-30 Thread Michael Kelly
On Fri, Sep 27, 2002 at 08:29:53PM -0500, Grant Hansen wrote: > Can anyone provide an example of how to use a state variable to break out of a > loop? > > Thanks I smell homework. But to be fair: what do you have so far? Why doesn't it do what you want? If you showed us your code where you wer

Re: State Variables

2002-09-27 Thread John W. Krahn
Grant Hansen wrote: > > Can anyone provide an example of how to use a state variable to break out of a > loop? Can you provide an example or explanation of what you are trying to do? John -- use Perl; program fulfillment -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands,