Background
In every other programming language I use on a regular basis, it is simple to operate on the return value of a function without declaring
PHP can not access array results from a function. Some people call this an issue, some just accept this as how the language is designed. So PHP makes you create unessential variables just to extract the data you need.
So you need to do.
$var = foobar(); print($var[0]);