Computer Science · Data Structures
एक सिंगली लिंक्ड लिस्ट (singly linked list) को उलटने (reverse) की समस्या पर विचार करें। O(1) सहायक स्पेस (auxiliary space) में इस समस्या को हल करने वाले एल्गोरिदम की समय जटिलता (time complexity) के बारे में निम्नलिखित में से कौन सा कथन सत्य (TRUE) है?
- 1O(1) स्पेस में सिंगली लिंक्ड लिस्ट को उलटना संभव नहीं है।
- 2इस समस्या के लिए सबसे अच्छा एल्गोरिदम वर्स्ट केस में θ(n2) समय लेता है।
- 3इस समस्या के लिए सबसे अच्छा एल्गोरिदम वर्स्ट केस में θ(n log n) समय लेता है।
- 4इस समस्या के लिए सबसे अच्छा एल्गोरिदम वर्स्ट केस (worst case) में θ(n) समय लेता है।✓
सही उत्तर देखें
इस समस्या के लिए सबसे अच्छा एल्गोरिदम वर्स्ट केस (worst case) में θ(n) समय लेता है।
Download Single Question PDF
Save this question and verified answer as a clean study sheet with live clickable link.
Share with Friends & Study Groups
Challenge your peer aspirants on WhatsApp or Telegram to solve this question!
Preparing for Computer Science?
Practice full-length mock tests with real exam timers, instant score analysis, and all-India ranking.
Want more practice questions on Data Structures?
Solve complete topic-wise tests with detailed solutions on GkGet.
Related Practice Questions
Recommended practice questions in Computer Science · Data Structures