The definition of a hash requires that all keys are unique. To use a
hash the way you want, you may need to make the value for the key
"Acorn Drive" a pointer to an array containing the data you intend [A,
B, ...]. You can use an "anonymous" array to hold the data you want.
(This is what the
If I understand correctly what you are trying to do can't be done with "normal"
hashes. Normally a hash can contain only one value for each unique key, and therefore
you overwrite the value each time you assign a value to a particular key. So you have
two obvious options (in other words that I
-Original Message-
From: Ben Crane [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 02, 2002 4:39 AM
To: [EMAIL PROTECTED]
Subject: modification on hashes/unique values
Hi,
a slight change to the previous mail: if I've got a
key (e.g. A, and I have 3 or 4 keys (which are all A)
which corres
Hi,
a slight change to the previous mail: if I've got a
key (e.g. A, and I have 3 or 4 keys (which are all A)
which correspond to different data...
e.g. Acorn Drive is a key, but there are several parts
the make up Acorn Drive...I want a key (Acorn drive)
to be able to refer to EVERY part of it..