Remove duplicates from Linked List

O(N) using STL map