Question: An Unsorted Type ADT is to be extended by the addition of function SplitLists, which has the following specifications: 1. Implement SplitLists as an array-based
An Unsorted Type ADT is to be extended by the addition of function SplitLists, which has the following specifications:
1. Implement SplitLists as an array-based member function of the Unsorted List ADT. 2. Implement SplitLists as a linked member function of the Unsorted List ADT.
SplitLists(Unsorted Type list, Item Type item, UnsortedType& list1, Unsorted Type& list2) Function: Preconditions: SplitLists(Unsorted Type list, Item Type item, Unsorted Type& list1, UnsortedType& list2) Postconditions: Divides list into two lists according to the key of item. list has been initialized and is not empty. list1 contains all the items of list whose keys are less than or equal to item's key; list2 contains all the items of list whose keys are greater than item's key.
Step by Step Solution
3.45 Rating (155 Votes )
There are 3 Steps involved in it
It seems like you want to create a member function SplitLists for the Unsorted List Abstract Data Ty... View full answer
Get step-by-step solutions from verified subject matter experts
