in reply to Perl Variables

Hi Nalina,

You can't do it that way.  But then, why would you want to have a hash whose name can differ, depending on your variable $tgs?

Just stick with a known hash name, like my %Test_hash.  It's lexically scoped to within the subroutine, so it can't interfere with anything outside of the subroutine.

If you really think you need to have a "dynamically named variable", please explain why you think so, and we can suggest an alternative that does what you need.


s''(q.S:$/9=(T1';s;(..)(..);$..=substr+crypt($1,$2),2,3;eg;print$..$/