what is logic of all operations in singly linked list
Answers
Answered by
2
Explanation:
Singly-linked list is a collection of nodes linked together in a sequential way where each node of the singly linked list contains a data field and an address field that contains the reference of the next node.
The structure of the node in the Singly Linked List is
class Node {
int data // variable to store the data of the node
Node next // variable to store the address of the next node
}
The nodes are connected to each other in this form where the value of the next variable of the last node is NULL i.e. next = NULL, which indicates the end of the linked list.
Similar questions