Search last item in an ArrayList and Linked List
- Write a java program that searches last item in an ArrayList and Linked List and prints the search time in milliseconds to check which collection is faster in traversing and searching a particular item.
NOTE: The data stored in both the collections is the same and the item searched is also fixed according to position in the collection.
e.g [23, 44, -9, 14, 123, 56, 223, 445, 33, 45, 89, 1, 0, 21, 100] and you are finding "100"(last item) in both the collections.