For doubly linked lists, there are two variants of the move-to-front and transpose methods (Matthews, Rotem,&Bretholz 1980). A move-to-end method moves an element being accessed to the end from which the search started. For instance, if the doubly linked list is a list of items A B C D and the search starts from the right end to access node C, then the reorganized list is A B D C. If the search for C started from the left end, the resulting list is C A B D.
The swapping technique transposes a node with this predecessor also with respect to the end from which the search started (Ng&Oommen 1989). Assuming that only elements of the list are in the data, what is the worst case for a move-to-end doubly linked list when the search is made alternately from the left and from the right? For a swapping list?
We need at least 10 more requests to produce the solution.
0 / 10 have requested this problem solution
The more requests, the faster the answer.