in reply to Where to declare?

Thanks very much for your help. The "while" loop definitely simplified things.

And this -
As a matter of fact, you should stay away from using & to call subroutines unless you understand how it's different from calling them with (). Calling with & makes @_ in the called subroutine an alias for @_ in the caller; () makes a copy instead. So changing the parameters in the subroutine could affect the variables used in the main program. This is probably not what you expect! Be careful.
- is definitely information I can use. I tend to be pretty liberal about using both "&" and "()" in my subroutine calls. I didn't realize there was a difference.

Thanks for the help and enlightenment...
Rich36

Replies are listed 'Best First'.
(tye)Re: Where to declare?
by tye (Sage) on Oct 24, 2001 at 23:36 UTC

    Actually, that bit of text you quoted is incorrect. Using & without () does what is described. Using both together is probably a good practice, especially if you aren't in the habit of giving your subroutines names with mixed case. See (tye)Re: A question of style for more info.

            - tye (but my friends call me "Tye")