Slicing array wrong, not getting any elements. Fixed