In other languages such as C# and JavaScript, I am able to access the index of an array with a function call such as
getMyArray()[0]
This
You need to be running PHP 5.4 in order to use array de-referencing.
// PHP 5.4 $item = getMyArray()[0]; // Older than 5.4: (not recommended) list($a) = getMyArray(); // getMyArray()[0] list(, $b) = getMyArray(); // getMyArray()[1]