in reply to Using a varabile contained within another variable?
First of all, in this piece of code, $y doesn't have anything to do with $x because it's single quoted, so $y contains a string which looks like $x
You might want to ref:
my $x = 1; my $y = \$x; $$y++; print $x;
Update: It turned out that $y has something to do with $x after all.. my bad. see lemming's post below..
|
|---|