in reply to Re: Confused by some var names in perlref
in thread Confused by some var names in perlref

I understand that it is much to late to change, but I would have preferred the name "associative array" because it describes the function of the structure. "Hash" may be more descriptive to the developers of perl, but to the rest of us, it is an implementation detail.

You seem to have found a bug in the glossary. If the word "septisyllabically" is correct, a definition should be provided. Neither dictionary.com nor google.com offer much help.

Bill
  • Comment on Re^2: Confused by some var names in perlref

Replies are listed 'Best First'.
Re^3: Confused by some var names in perlref
by Eily (Monsignor) on Dec 05, 2018 at 22:05 UTC

    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.

      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.
      Bill
Re^3: Confused by some var names in perlref
by pryrt (Abbot) on Dec 05, 2018 at 21:54 UTC

    "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)

        German famously pastes words together to get new ones. The one that I use as illustrative for english speakers is "genital traffic" = Geshlechtsverkehr, = sex.