linked list duplicate removal