Untitled

Anonymous
plain_text
10/08/2023 1:57 PM
512 B
19
Indexable
Class Node { 
     int data;    the data of this node is stored here
     Node next;   the reference to the next node is here(the beloved pointer)
     
     public Node(int data)  {
          this.data = data;
          this.next = null;
    }
}

class LinkedList {
    Node head;
    public void addNode(int data){}
    public void deleteNode(int data){}
}
Editor is loading...