In the AutoHotkey forum, I suggested this language would gain by having true array and associative array support. Since it is a late addition, syntax has to fit in the current language, with some adaptations since it will go through a v.2 supporting incompatible changes.
Anyway, I thought it would be a good idea to show how such objects are supported in some popular scripting languages. The demonstration is limited, by lack of time and knowledge: I don't know Python, I am not an expert of Perl (plus it has a quite exotic syntax), etc. So I chose three languages I know well enough, and tried to write similar scripts, or at least having similar output, while remaining native as much as possible.
It was very interesting and educational, I learnt a lot in the process... I hope it will be educational for you too.
This is not intended to be a reference, there are lot of good pages on the topic. So I just give code with some comment, you have to do the rest of the job...
The pages themselves are not very interesting: it is merely the output of the scripts, quite raw. But you can connect it to the corresponding lines of code, seing their result.
A quick survey of the differences between the languages.
Lua 5.0 allows to mix freely array (with numerical indexes) and table (associative array) in the same object. It maintains an array part, with quick numerical access to fields, as long as the indices are successive (without gap). Large disjoint indices and string keys are kept in a hash table.
Lua's philosophy for the base functions is to provide as little as possible while remaining convenient, ie. providing functions that cannot be done in Lua, or too slowly (like sort). The idea is that one can easily extend this list of functions with some Lua functions, or even C functions.
Note that I chose to stick to Lua 5.0 syntax and functions instead of using Lua 5.1's. But I made the output with Lua 5.1, because 5.0 has some quirks that I avoided...
PHP 4+ can also store either with numerical or string indices.
PHP's array functions is significant of the quite anarchic development of the language... Everybody provided functions in the field, and no moderator tried to make them consistent, in name (shuffle vs. array_rand, sort vs. array_multisort) or in parameter lists. Having lot of functions might seem nice, but it is confusing to the user (which sort function to choose?) and lot of functions are probably rarely used and could easily be done with an iteration on the members (array_product...)