Also, Perl 5 is feature-stable, and probably always will be. Python is in this 2.x-3.x limbo right now where it's difficult to find libraries that are going to work as-is for much longer. If you write a Perl application well, maintenance will as easy as reasonably possible, which I think is the only real measure of a good language. Most of the 'ease of use' problems disappear once you know what you're doing, and the language learning curve is a relatively small part of a programmer's life-cycle.
I can imagine it looking worrisome from the outside, though.
Indeed it is.
Perl has supported arrays of arrays since 1994.
Pointers are not reasonable in a high level language.
Perl has never supported pointers.
Explicit function signatures are a superior language design.
I agree with this. Perl 5 should have had them years ago.
You mean "array" instead of "list", but yes. Are there languages which don't require some special syntax for accessing nested data structures?
Otherwise you get what looks to my eye like a pointer (a weird random number).
When you stringify a reference, you get either the default stringification or an overloaded stringification, if you've overloaded stringification for a particular class. When you numify a reference, you get a unique number. Think of it as a cheap object identifier, because that's effectively what it is. It's not a great interface to expose to users, but that's its intent.
I argue that it's not a pointer, because you can't do pointer arithmetic with it.
...pointers are not a distinct type...
You mean "reference", and indeed they are distinct. They're RVs. That's a scalar type (SV).
Isn't that true for... most languages? Python, Ruby, Java, PHP, Smalltalk. And any language created in modern times. Perl in this respect is like a transitional animal in the evolution of languages -- what seemed somewhat modern given its peers (like shell or Tcl) now seems horribly outdated, the programming language world moved on having considered nested data structures a solved problem. It's like goto or dynamically scoped variables in other eras.
@aoa = ( [ 1, 2, 3 ], [ 4, 5, 6 ] );
How to make a list of lists in Python: lol = [ [ 1, 2, 3 ], [ 4, 5, 6 ] ]
How to access the second element of the second array in Perl 5: $aoa[1][1];
How to access the second element of the second list in Python: lol[1][1]
The difference seems to be nomenclature and Perl's use of sigils. Where's the "horribly outdated" design?I could give you examples of Ruby's and Python's inconsistency in their use of parentheses, as sometimes they group expressions to influence parsing precedence and sometimes they denote first-class data structures, but as you persist in asserting that parentheses create lists in Perl and that lists are first-class data structures, I suspect this discussion will continue to go nowhere.