in reply to incrementing array name
This is a terribly dirty thing to do, combining symbolic references and global variables, but I'm lowdown enough to show you how:
{ my $name = 'a'; sub separate_data { @{$name++} = split / /, $_[0]; } }
You'll need to do that under no strict qw(vars refs); . Can you think of a better design for what you're doing? Hint: hash.
After Compline,
Zaxo
|
|---|