By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
437,692 Members | 1,998 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 437,692 IT Pros & Developers. It's quick & easy.

break in perl

P: 51
How to come forcefully come out of a loop,but not from the program,
like we use break statement in c. Is there any predefined function like break in perl?

May 28 '08 #1
Share this Question
Share on Google+
2 Replies

Expert 100+
P: 410
Hi pavan,

'last' works like break in C. To give you a brief overview of control statements:
last - come out of the statement block
next - terminate current iteration and continue with next iteration(used in loops)
continue - continue with the next block
exit - exit the program/script

May 28 '08 #2

P: 9
If you want it quickly:
Jul 8 '08 #3

Post your reply

Sign in to post your reply or Sign up for a free account.