reverse works, sorting doesn't