Question: Consider the following implementations for Queue, which one supports more efficient DEQUEUE operations? Assume all linked lists used keep both head and tail references. Question
Consider the following implementations for Queue, which one supports more efficient DEQUEUE operations? Assume all linked lists used keep both head and tail references.
Question Answer
A
Singly linked list with head being queue rear and tail being queue front.
B
Singly linked list with head being queue front and tail being queue rear.
C
Both are equally efficient.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
