Deduplicate linked list