Demo program for java.util.LinkedList Adding items to the list There are 4 items in the list. Here is the list, output method 1 item1 item2 item3 item4 Here is the list, output method 2 item1 item2 item3 item4 Here is the list, output method 3, using toString() [item1, item2, item3, item4] removed : item2 Here is the list after removal of an item item1 item3 item4 Adding (inserting) item back to it's position Here is the list after additon of item item1 item2 item3 item4 Adding several more items Here is the list after addition of several items, unsorted item1 item2 item3 item4 item9 item6 Sorting items Here is the list after sorting item1 item2 item3 item4 item6 item9 Searching for Hello Item NOT found Searching for item8 Item NOT found The LinkedList is almost identical to the ArrayList However it has some additional methods such as addFirst method - which adds an item to the beginning of the list Adding items using addfirst method Here is the list after adding items to the beginning [item7, item5, item1, item2, item3, item4, item6, item9]