in reply to array of arrays - context problem
For the benefit of potentilal newbies, here is a clarification on what went wrong with the original code :
It did NOT DWIM !my @masterarray = qw(@array1 @array2 @array3);
As you have discovered, that code is equivalent to :
and this is clear in examples the documentation for qw (perldoc perlfunc).my @masterarray = ('@array1','@array2','@array3');
Although it is not explicit in the documentation, the qw operator DOES NOT INTRAPOLATE.
..."I don't know what the facts are but somebody's certainly going to sit down with him and find out what he knows that they may not know, and make sure he knows what they know that he may not know, and that's a good thing. I think it's a very constructive exchange," --Donald Rumsfeld
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: array of arrays - context problem
by chb (Deacon) on Jan 14, 2005 at 06:54 UTC |