in reply to Re^2: Mistake in data structure use?
in thread Mistake in data structure use?
The error message is exactly right. The first element of the array reference you've assigned to person is the value 0, which is not a hash reference. It's a plain scalar value. In Perl, you don't assign pairs of indices and values to arrays. Perl will automatically use the correct index numbers when you assign a list to an array.
Do what the first commenter suggested and your code will work better.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Mistake in data structure use?
by McLogic (Initiate) on Dec 04, 2006 at 16:31 UTC |