I don't think associative array is a good name either. Depending on which language you come from array might mean "ordered list" to you, and I don't think the "associative" in the name would be of any help if you don't know the concept in the first place.
Other languages have other names for hash-like objects, like map (eg C++), which because of the map keyword would be a pretty bad idea in perl (I must admit that I had a lot of trouble understanding map precisely because I only knew the world as meaning "hash-like object" when I learned perl). Some languages have dictionaries, or dict (like python), which isn't a bad name I suppose. For what it's worth, in raku (perl 5's little sister) the association feature can be implemented either by using the base type hash, or an object implementing the Role "Associative".
If the word "septisyllabically" is correct, a definition should be provided. It's a neofrankenlogism, with a latin prefix, a greek root and -ally for adverbing that indicates the use of an heptasyllabe (and if my jokes still don't help, it means "with seven syllabes"). It's consistent with the spirit of perl's documentation and, as far as I can tell, Tim Toady's interest in linguistic related subjects. I guess it might be a little unhelpful for new comers though.
| [reply] |
Thanks for the explanation. Because I failed to decipher the strange word, I did not get the joke, not even the point. 'Associative array' is a rather long name. However, I still would have preferred it over 'hash'. When I was first learning Perl, I naively thought of an array as a structure which associated values with integers and A 'associative array' as a special kind of array which associated the values with strings instead of integers. The syntax for accessing values from either one is consistent with this view. The name 'hash' is not misleading simply because it does not offer a hint about how to use the structure or what it might be used for.
| [reply] |
"septisyllabically" was probably an intentional neologism, in an attempt to be clever: "septi" from "septum", which is Latin for "seven", "syllabi" from "syllable", "ically" = "in the manner of": ie, "it's a seven-syllable way of saying 'associative array'" ('associative array' does indeed have seven syllables)
| [reply] |
> "septisyllabically" was probably an intentional neologism
I wouldn't call it a neologism, rather a construction.
It's as logical as
if you can count in Greek Latin*, that is. ;-)
update
NB: the same word in German - siebensilbig - is shorter and easily understood by German speakers.
*) doh ... thanks Eily++ ... see also Numeral_prefix
| [reply] |
| [reply] |