On Jul 5, 10:21 pm, [EMAIL PROTECTED] wrote: > > I am reading perldoc.perl.org and am not understanding exit > > and die clearly. > > > If I have a conditional in a sub that I want to validate with, > > what is the correct way to do the following: > > > 1. End the sub and return back to the script without > > continuing that sub. > > if (condition){last} gets you out of that loop
The OP said nothing about having a loop. He wants to exit the subroutine. For that, you need 'return'. Not 'last'. Paul Lalli -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/