finish implementing splitAt in all cases