Think about Loose Coupling | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
The key thing to remember is that you can only store a scalar as a data structure value. So in the context of an array each element is a scalar - the element's value may reference something more interesting like another array, but the value is a scalar. You may find it helps to assign the reference to a temporary variable with a suitable name even in trivial cases so that you make it clear to yourself that what you are dealing with is a reference. Only the very innermost element can be a non-reference scalar value (a string or number for example). It may help to show us some of the code and the data structures that give you grief so we have a concrete example to work with that applies to what you are using.
True laziness is hard work
In reply to Re^3: Nested Data Structures for Dummies?
by GrandFather
|
|