The best performance improvement is the transition from the nonworking state to the working state. John Ousterhout

Insert sorted linked list

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

Data structure Description

Write a program to insert the new element in the sorted linked list.

If the element has high or low value, it should insert appropriate place in sorted linked list. Linked list has the only address of next node. Whenever to insert a new element in the linked list, the list should able to sort and insert to the appropriate location.



Insert items in LinkedList:9
Insert items in LinkedList:43
Insert items in LinkedList:34
Insert items in LinkedList:11
Insert items in LinkedList:78
Insert items in LinkedList:55
Sort items in LinkedList:9->11->34->43->55->78->NULL



No comments available!

Please login to add comments.