• Courses
  • Tutorials
  • Jobs
  • Practice
  • Contests

GATE | GATE-CS-2016 (Set 1) | Question 20

A queue is implemented using an array such that ENQUEUE and DEQUEUE operations are performed efficiently. Which one of the following statements is CORRECT (n refers to the number of items in the queue)?

(A)

Both operations can be performed in O(1) time

(B)

At most one operation can be performed in O(1) time but the worst case time for the other operation will be Ω(n)

(C)

The worst case time complexity for both operations will be Ω(n)

(D)

Worst case time complexity for both operations will be Ω(log n)

Answer

Please comment below if you find anything wrong in the above post
Feeling lost in the world of random DSA topics, wasting time without progress? It's time for a change! Join our DSA course, where we'll guide you on an exciting journey to master DSA efficiently and on schedule.
Ready to dive in? Explore our Free Demo Content and join our DSA course, trusted by over 100,000 geeks!

Last Updated :
Share your thoughts in the comments