Question

What is the time complexity for performing enqueue and dequeue operations on a queue implemented using a linked list?

A O(n) for both
B O(log n) for both
C O(1) for both
D O(1) for enqueue, O(n) for dequeue
E O(n) for enqueue, O(1) for dequeue
Practice Next

Hey! Ask a query