Re^5: Noob could use advice on simplification & optimizationby thundergnat (Deacon)
|on May 08, 2012 at 12:48 UTC||Need Help??|
'my' variables are lexical to the enclosing block. Here, since the variables are declared in the MAIN package, outside of any block, they are global, or visible to all all blocks within the package MAIN.
Declaring a variable with 'our' makes the the variable lexical to all enclosed blocks even across package boundaries.
See perldoc -f my and perldoc -f our for more explanation.