tsk1979 has asked for the wisdom of the Perl Monks concerning the following question:
Now I can use a hash like my %results for diffresult and %dispatcharray for my subroutine dispatching. But I do not know what all elements can be in @diffarray. So I am using var varname. Its giving me "Bareword error"@diffarray = (test, info, path.....) ## Its machine generated so can +have 15-20 elements too foreach $element (@diffarray) { @{$element}_diffresult = {$element}_subroutine(); } ## The subroutines are also machine generated
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Alternative to varvarname
by Corion (Patriarch) on Apr 07, 2006 at 11:40 UTC | |
|
Re: Alternative to varvarname
by GrandFather (Saint) on Apr 07, 2006 at 11:38 UTC | |
|
Re: Alternative to varvarname
by aquarium (Curate) on Apr 07, 2006 at 11:49 UTC |