|
|
| Just another Perl shrine | |
| PerlMonks |
Re: getting a while loop to terminateby thezip (Vicar) |
| on Apr 15, 2012 at 03:55 UTC ( #965121=note: print w/ replies, xml ) | Need Help?? |
|
It's because you have set $flag to '0', which is an uninterpolated string containing the character '0', a true value. Instead, you should set $flag to zero, (0), without the single quotes. This will evaluate to false and make your logic all happy. What can be asserted without proof can be dismissed without proof. - Christopher Hitchens, 1949-2011
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||||||||||||