I'm not sure I get your question but If you have problems exiting a loop I think you need to read about flow control, see next and last (and also continue) availible via perldoc -f for more info on the topic.
In reply to Re: working with foreach, nestd if's inside
by thunders
in thread working with foreach, nestd if's inside
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |