Any variable you declare with my @foo here will disappear at the end of the loop.while (my @foo = ...) { ... }
Instead, phrase it like:
If you had use strict; Perl would have complained on your final lines because the variables wouldn't exist at that time.my @foo; while (@foo = ...) { ... }
--
[ e d @ h a l l e y . c c ]
In reply to Re: How can I keep the values in the array?
by halley
in thread How can I keep the values in the array?
by luoina
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |