FANDOM


Objective The objective of this lab is to understand List ADT using Linked list implementation. Task Create a linked list and implement methods to insert item at the end of the list and display all items in the list. Use constructor as needed. Procedure  The implementation of Linked List uses a pair of classes. One describes the node and second represents the collection of nodes as a list structure. Implement following list of methods for linked list. Once you successfully implemented the above task, convert it to generic implementation. class Node { int data; Node next; Node(int d){ Data=d; } } class Linkedlist { Node head; public void insert(int d){ / / code } public Boolean find(int d){ // code } public void clear(){ // code } public void delete(){ // code} public String toString(){ // code } }