in reply to Scope Puzzle

There are two kinds of variables in Perl: lexical (my) variables and package (our) variables. If you don't declare a variable, Perl assumes it's a package variable.

Symbolic references (e.g. ${'varname'}) can only fetch and set the value of package variables.

Symbolic references are strongly discouraged. In fact, they won't even work if you use use strict as you should. Hashes or arrays usually do the trick. If you're looking to create aliases, check out Data::Alias.

(I wrote this earlier, but forgot to post it.)