Question: Suppose we want to extend the PositionalList abstract data type with a method, indexOf(p), that returns the current index of the element stored at position
Suppose we want to extend the PositionalList abstract data type with a method, indexOf(p), that returns the current index of the element stored at position p. Show how to implement this method using only other methods of the Positional-List interface (not details of our LinkedPositionalList implementation).
Step by Step Solution
3.54 Rating (182 Votes )
There are 3 Steps involved in it
public int indexOfPosition p ... View full answer
Get step-by-step solutions from verified subject matter experts
