working array return, conditionals