Which of the following statements are true about doubly linked list?(i) It may be either linear or circular(ii) It must contain a header node(iii) It will occupy same memory space as that of linear linked list, both having same number of nodes
Doubly linked list may be either linear or circular statements are true:-
Doubly linked list:-
A doubly linked listis a linked data structure that consists of a set of sequentially linked records called nodes. Each node contains two fields, called links that are references to the previous and to the next node in the sequence of nodes.
Circular linked list:-
Circular linked listis a linked list where all nodes are connected to form a circle. There is no NULL at the end. A circular linked list can be a singly circular linked list or doubly circular linked list.
Linear linked list:-
A linked list is a linear data structure where each element is a separate object. Each element of a list is comprising of two items, the data and a reference to the next node. The last node has a reference to null. The entry point into a linked list is called the head of the list.