If I call a sub I can get at all the other values in my script anyway, and I've never bothered passing variables to them. But looking through various posts to this group, and in various other places, a lot of people tend to pass the variables the sub needs to it, and pick them up with @_ - even though they're available anyway.
Does this actually do anything useful - like speed up the program perhaps? Or is it just efficient use of memory, or 'traditional' coding.. because I've never done it and just rely on the fact that I know what values I've got in the rest of the program. Am I missing out on something?
Cheers,
Matt.
Does this actually do anything useful - like speed up the program perhaps? Or is it just efficient use of memory, or 'traditional' coding.. because I've never done it and just rely on the fact that I know what values I've got in the rest of the program. Am I missing out on something?
Cheers,
Matt.