merges whales. added test cases for part 4