3 ms·
For those that don't know PHP associated arrays are equivalent pythons dictionaries. They are implemented as an ordered map. https://www.php.net/manual/en/l
by acomjean 7y ago
For those that don't know PHP associated arrays are equivalent
pythons dictionaries. They are implemented as an ordered map.
https://www.php.net/manual/en/language.types.array.php https://www.php.net/manual/en/language.types.array.php
Its pretty much the main data type used in php. Once you get used to it is pretty powerful for dynamic languages. They even have built in sorts:
https://www.php.net/manual/en/array.sorting.php https://www.php.net/manual/en/array.sorting.php
They are "simple arrays" that have numeric indexes, but I find those used less frequently. (They can morph into the key->value pair).
- tylerjwilk00 7y agoYour point got me thinking... PHP arrays may have been one of the "killer features" that lead to it taking hold of the web. It's so frictionless, powerful, and you can bend them to your will with ease.