This is why you will hear experienced Perlers (Perlizens?) insist that an array is not a list. If you understand that an array is a list interpreted in numeric indexed order and a hash is a list interpreted in pairwise key value fashion, then you are more likely to perform "list" operations when beneficial. I think the Perl literature needs to do more than it already does to make a "list" a real, live actual data structure, distinct from the array and hash "storage" of lists.
I have been a software professional since I was in high school in 1998. I'm enthusiastic about open source, and I really enjoy working in unusual software systems or within strange constraints.
I have been a software professional since I was in high school in 1998. I'm enthusiastic about open source, and I really enjoy working in unusual software systems or within strange constraints.
Yeah, most dynamic languages seem to have this same difference. I think that for beginners it is semantics, but for those who are starting to come into their own in their coding practice it's a super important concept to understand.
Thanks for this contribution!
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
This is why you will hear experienced Perlers (Perlizens?) insist that an array is not a list. If you understand that an array is a list interpreted in numeric indexed order and a hash is a list interpreted in pairwise key value fashion, then you are more likely to perform "list" operations when beneficial. I think the Perl literature needs to do more than it already does to make a "list" a real, live actual data structure, distinct from the array and hash "storage" of lists.
What does this semantic difference mean for those writing code?
It means they realize they can do list-y type things and not resort to loops, i.e. the answer to your followup question is your article. :-)
Or, more precisely, if the semantic difference was more distinctly taught, you wouldn't have had to write your article.
Yeah, most dynamic languages seem to have this same difference. I think that for beginners it is semantics, but for those who are starting to come into their own in their coding practice it's a super important concept to understand.
Thanks for this contribution!