MCQ IN COMPUTER SCIENCE & ENGINEERING

COMPUTER SCIENCE AND ENGINEERING

DATA STRUCTURES

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
How to create very first node in a Doubly Linked List which is initially empty? Assume head pointer variable is L
A
newnode
B
newnode
C
newnode
D
newnode
Explanation: 

Detailed explanation-1: -Only the first node (head) has its previous node set to null and the last node (tail) has its next pointer set to null. As the doubly linked list contains two pointers i.e. previous and next, we can traverse it into the directions forward and backward.

There is 1 question to complete.