Beware of bugs in the above code; I have only proved it correct, not tried it. Donald E. Knuth

Remove duplicate

Language Java | Level Intermediate | Category Data structure | September 5, 2015 10:13 pm

Data structure Description

Write a program to remove the duplicate elements from the linked list. Each node in Linked list has data and next node pointer. Search the data in the linked list and remove the duplicate item from the linked list.

Example if a linked list contains 2->3->1->3->4 then the result should be 2->3->1->4



Print the list of items: 21->52->33->21->67->NULL
Print the list of items after remove duplicate: 21->52->33->67->NULL



No comments available!

Please login to add comments.