in reply to organizing program structure
I've never written any Perl script without subroutines (known as functions in other programming languages).
You don't need to use goto, you define subroutine and call it like this:
# define it sub Add { my ($x,$y) = @_; return $x + $y; } # call it print Add(5,3); # it will print out 8
You may want to tell us what's the problem you are trying to solve so we can help you deciding what would work for you.
|
|---|