Properly separate the head and tail.