Then I am confused about the lastChar logic. And also why split over space (Line 81)?