in reply to Re^4: Hash part linking
in thread Hash part linking
If I understand you correctly, you're trying to link an element in one array to another array (in a hash of arrays). In other words, you want to add an arrayref to an array. The solutions posted by both Limbic~Region and borisz do exactly that. Unless we are still misunderstanding your problem, you might want to peruse perlref to gain a more thorough understanding of references. References are very powerful tools that will serve you well, provided you know how to use them effectively.
On the other hand, I wonder why you need an arrayref at all. Could you not simply use the words in the definition directly as hash keys?
HTH, bobf
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^6: Hash part linking
by chiburashka (Initiate) on Aug 14, 2004 at 17:27 UTC | |
by bobf (Monsignor) on Aug 14, 2004 at 17:50 UTC | |
|