The reason why the goto command is not generally used in perl (and other
languages) is that it does not force the developer to have a theoretical
framework for the program. It creates 'spagetti code' where a person working
on the code or trying to understand what the developer has done has to
follow a rabbit tunnel of goto directions. A direct alternative is using sub
procedures which not only perform the same goto like movement, but can use
parameters and return values as well.

"Thomas Browner" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Does perl have a goto command. For example if you tell scrip to do
> something and it returns a 1 then it should go to a block of code that
> does something else.
>
> Thanks,
> Thomas Browner
>
>
>



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to