Question DSA-QUE-0015
HardIn an array-based circular queue of capacity n, how can a full queue be told apart from an empty one if both have front == rear?
- A.
Keep a count of elements (or leave one slot unused)
- B.
It is impossible
- C.
Check whether the array is sorted
- D.
Use a second array
Sign up free to see the answer and a step-by-step explanation.