Question 24Asked in Bihar STET 2024 Paper II Computer Science, 11 Jun 2024, Shift 1 (10:00 AM)

Counting Sort is particularly efficient for sorting arrays where the range of elements is:गिनती सॉर्ट विशेष रूप से सरणियों को छांटने के लिए कुशल है जहां तत्वों की सीमा है:

गिनती सॉर्ट विशेष रूप से सरणियों को छांटने के लिए कुशल है जहां तत्वों की सीमा है:
  1. AVery largeबहुत बड़े
  2. BVery smallबहुत छोटे
  3. CConstantनिरंतर
  4. DSortedक्रमबद्ध
Show answerHide answer

Correct answer: (B) Very smallबहुत छोटे

Explanation

Counting sort runs in O(n + k), where k is the range of key values, so it is efficient only when that range is small compared with n.Counting sort O(n + k) में चलता है, जहाँ k कुंजी-मानों की सीमा है, इसलिए यह तभी कारगर है जब वह सीमा n की तुलना में छोटी हो।

From Bihar STET 2024 Paper II Computer Science PYQ, 11 Jun 2024, Shift 1 (10:00 AM)

This is question 24 of Bihar STET 2024 Paper II Computer Science PYQ, 11 Jun 2024, Shift 1 (10:00 AM). See all questions of this paper with answers, or attempt the paper as a timed online test to get your score and all-India rank.