Hello all,
Is there any way to turn text from an array into variables?
ie.
my @array = qw(one two three);
my $array = '$' . join(',$', @array); # should give $one,$two,$three
my ($array); # should instantiate?
$one = 1;
$two = 2;
$three = 3;
my $ans = $one + $two + $three;
print "Answer is : $ans.";
I run this but apparently 'my ($array);' doesn't really instantiate
the variables.
Is there any way to do this?
Thanks,
Shawn
--------------------
Shawn Michael Hinchy
[EMAIL PROTECTED]
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>