Without arguing the merits of symbolic reference (merits they say... what merits?), this will do it.
#!/usr/bin/perl our @bar = qw(One Two Three); my $foo = "bar"; print "***" . $foo . "***\n"; foreach (@$foo) { print $_ . "\n"; }
In reply to Re: Create an array reference from a string
by Sandy
in thread Create an array reference from a string
by xorl
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |