Transform Array Into List Python Functions With Return