Which type of linked list is most suitable for implementing a queue data structure?कतार डेटा संरचना को लागू करने के लिए किस प्रकार की लिंक की गई सूची सबसे उपयुक्त है?
कतार डेटा संरचना को लागू करने के लिए किस प्रकार की लिंक की गई सूची सबसे उपयुक्त है?
Show answerHide answer
Correct answer: (A) Singly linked listएकल लिंक्ड लिस्ट
Explanation
A singly linked list with front and rear pointers gives O(1) enqueue at the rear and O(1) dequeue at the front, so no backward links are needed.आगे और पीछे के pointers वाली singly linked list पीछे से O(1) में enqueue और आगे से O(1) में dequeue देती है, इसलिए पीछे की ओर जाने वाले लिंक की ज़रूरत नहीं है।