Explore topic-wise InterviewSolutions in .

This section includes InterviewSolutions, each offering curated multiple-choice questions to sharpen your knowledge and support exam preparation. Choose a topic below to get started.

251.

How many elements can be sorted in O(logn) time using Heap sort?(a) O(1)(b) O(n/2)(c) O(logn/log(logn))(d) O(logn)The question was asked during an interview for a job.Question is from Heapsort in division Sorting of Data Structures & Algorithms II

Answer»

Correct choice is (c) O(logn/log(logn))

The EXPLANATION is: The time complexity of Heap sort is O(klogk) for K input ELEMENTS,

for k = logn/log(logn),

O(klogk) = O(logn/log(logn) * log(logn/log(logn)))

∴ O(klogk) = O(logn/log(logn) * (log(logn) – log(log(logn))))

= O(logn)

HENCE the correct option is O(logn/log(logn)).

252.

Introsort algorithm is combination of _____________(a) Quick sort and Heap sort(b) Quick sort and Shell sort(c) Heap sort and Merge sort(d) Heap sort and insertion sortThe question was asked in examination.My question comes from Heapsort in section Sorting of Data Structures & Algorithms II

Answer»

The correct OPTION is (a) QUICK sort and HEAP sort

Easy explanation - Introsort is a hybrid sorting algorithm that combines Quick sort and Heap sort to retain advantages of both. It has WORST case speed of Heap sort and average case speed of Quick sort.

253.

Which one of the following is a variation of Heap sort?(a) Comb sort(b) Smooth sort(c) Binary tree sort(d) Shell sortThis question was posed to me in exam.Question is taken from Heapsort topic in chapter Sorting of Data Structures & Algorithms II

Answer»

Correct ANSWER is (b) Smooth sort

Easy EXPLANATION - Smooth sort is a variation of Heap sort. Smooth sort has O(nlogn) WORST case TIME complexity like Heap sort. But Smooth sort takes O(n) time to sort the nearly sorted input array.

254.

In average case Heap sort is as efficient as the Quick sort.(a) True(b) FalseI got this question in examination.The above asked question is from Heapsort in chapter Sorting of Data Structures & Algorithms II

Answer» RIGHT option is (b) False

For explanation: Quick sort is more EFFICIENT than Heap sort because EXPERIMENTS indicate that Heap sort requires twice as much TIME as Quick sort for randomly sorted INPUT.
255.

What is its wort case time complexity of Heap sort?(a) O(nlogn)(b) O(n^2logn)(c) O(n^2)(d) O(n^3)The question was asked in a national level competition.The above asked question is from Heapsort topic in section Sorting of Data Structures & Algorithms II

Answer»

The correct choice is (a) O(nlogn)

Easy EXPLANATION - In Heap sort, the call to procedure build_Max-heap takes O(N) TIME and each of O(n) calls to the function max_Heapify takes O(logn) time. So the WORST case complexity of Heap sort is O(nlogn).

256.

The descending heap property is ___________(a) A[Parent(i)] = A[i](b) A[Parent(i)] = A[i](d) A[Parent(i)] > 2 * A[i]This question was posed to me in exam.Question is from Heapsort topic in section Sorting of Data Structures & Algorithms II

Answer»

The correct option is (c) A[Parent(i)] >= A[i]

For EXPLANATION: The max-heap is also KNOWN as descending heap. Max-heap of SIZE n is an almost complete BINARY tree of n nodes such that the element at each node is LESS than or equal to the element at its parent node.

257.

The essential part of Heap sort is construction of max-heap. Consider the tree shown below, the node 24 violates the max-heap property. Once heapify procedure is applied to it, which position will it be in?(a) 4(b) 5(c) 8(d) 9I got this question in examination.My doubt stems from Heapsort topic in section Sorting of Data Structures & Algorithms II

Answer»

Right choice is (d) 9

Explanation: In max-heap element at each node is smaller than or EQUAL to the element at its PARENT node. On applying the heapify PROCEDURE on item at position 2, it will be in position 9 as shown below.

258.

Which one of the following is false?(a) Heap sort is an in-place algorithm(b) Heap sort has O(nlogn) average case time complexity(c) Heap sort is stable sort(d) Heap sort is a comparison-based sorting algorithmThe question was posed to me during an interview.Question is from Heapsort in section Sorting of Data Structures & Algorithms II

Answer»

Right option is (c) Heap sort is stable sort

Best EXPLANATION: Heap sort is a COMPARISON based sorting algorithm and has time complexity O(nlogn) in the average case. Heap sort is an in-place algorithm as it needs O(1) of AUXILIARY space. Heap sort uses heap and operations on heap can change the relative order of items with the same key VALUES. Therefore, Heap sort is not a stable sort.

259.

Heap sort is an implementation of ____________ using a descending priority queue.(a) insertion sort(b) selection sort(c) bubble sort(d) merge sortThe question was asked at a job interview.This question is from Heapsort in section Sorting of Data Structures & Algorithms II

Answer»

Right CHOICE is (b) selection sort

Explanation: HEAP sort is an implementation of selection sort using the input array as a heap representing a descending priority queue. Heap sort algorithm is divided into two PHASE. In first phase the max-heap is created and the SECOND phase (selection phase) DELETES the elements from the priority queue using siftdown operation.

260.

What is the average number of comparisons used to heap sort a random permutation of N distinct items?(a) 2N log N-O(N)(b) 2N log N-O(N log N)(c) 2N log N-O(N log log N)(d) 2N log N-O(log N)I got this question in an interview for job.This question is from Heapsort topic in division Sorting of Data Structures & Algorithms II

Answer» CORRECT answer is (c) 2N log N-O(N log log N)

Explanation: According to a theorem, the average NUMBER of COMPARISONS used to heap sort a random PERMUTATION of N distinct items is found to be 2N log N-O(N log log N).
261.

What is the time taken to copy elements to and from two arrays created for deletion?(a) O(N)(b) O(N log N)(c) O(log N)(d) O(N^2)The question was posed to me in an international level competition.This intriguing question comes from Heapsort in section Sorting of Data Structures & Algorithms II

Answer»

Right choice is (a) O(N)

BEST explanation: The TIME taken to copy ELEMENTS to and from the MAIN array and extra array is found to be O(N).

262.

What is the average number of comparisons used in a heap sort algorithm?(a) N log N-O(N)(b) O(N log N)-O(N)(c) O(N log N)-1(d) 2N log N + O(N)The question was posed to me during an interview.This is a very interesting question from Heapsort in section Sorting of Data Structures & Algorithms II

Answer»

Correct answer is (d) 2N LOG N + O(N)

The best I can explain: The AVERAGE number of COMPARISONS in a heapsort algorithm is mathematically found to be 2N log N + O(N).

263.

Heap sort is an extremely stable algorithm.(a) true(b) falseThe question was posed to me in quiz.My enquiry is from Heapsort topic in chapter Sorting of Data Structures & Algorithms II

Answer»

Correct choice is (a) true

Explanation: HEAP sort uses fewer comparisons than other sorting algorithms and HENCE it is an EXTREMELY stable algorithm.

264.

What is the time taken to perform a delete min operation?(a) O(N)(b) O(N log N)(c) O(log N)(d) O(N^2)This question was addressed to me in an online quiz.This is a very interesting question from Heapsort in division Sorting of Data Structures & Algorithms II

Answer»

Correct option is (C) O(log N)

The best I can explain: The time TAKEN to perform a DELETION of a minimum ELEMENT is mathematically FOUND to be O( log N).

265.

How many arrays are required to perform deletion operation in a heap?(a) 1(b) 2(c) 3(d) 4This question was posed to me in examination.Asked question is from Heapsort topic in division Sorting of Data Structures & Algorithms II

Answer»

The CORRECT CHOICE is (b) 2

Best explanation: To perform deletion operation in a HEAP, we require 2 arrays and that OCCUPIES extra memory space and hence increase in running time.

266.

What is the typical running time of a heap sort algorithm?(a) O(N)(b) O(N log N)(c) O(log N)(d) O(N^2)This question was posed to me during an interview.Question is taken from Heapsort topic in chapter Sorting of Data Structures & Algorithms II

Answer»

The CORRECT answer is (b) O(N log N)

The best explanation: The total running time of a heap sort ALGORITHM is MATHEMATICALLY FOUND to be O(N log N).

267.

In heap sort, after deleting the last minimum element, the array will contain elements in?(a) increasing sorting order(b) decreasing sorting order(c) tree inorder(d) tree preorderThis question was posed to me in exam.I would like to ask this question from Heapsort topic in chapter Sorting of Data Structures & Algorithms II

Answer»

The correct option is (b) decreasing SORTING order

Explanation: By logic, after DELETING minimum element, the HEAP will contain elements in decreasing sorting order. We can CHANGE this by altering the ORDERING property.

268.

In what position does the array for heap sort contains data?(a) 0(b) 1(c) -1(d) anywhere in the arrayThis question was addressed to me in an online quiz.This question is from Heapsort in portion Sorting of Data Structures & Algorithms II

Answer»

Right option is (a) 0

Easy explanation - The array for heap sort contains data at position 0 whereas for a BINARY heap, array BEGINS at 1. This is the reason for its COMPLEXITY.

269.

Consider the following heap after buildheap phase. What will be its corresponding array?(a) 26,53,41,97,58,59,31(b) 26,31,41,53,58,59,97(c) 26,41,53,97,31,58,59(d) 97,53,59,26,41,58,31I got this question during a job interview.This key question is from Heapsort in chapter Sorting of Data Structures & Algorithms II

Answer»

The CORRECT option is (d) 97,53,59,26,41,58,31

Easy EXPLANATION - Constructing a MAX heap USING the elements 97,53,59,26,41,58,31 will cause the heap to look like that.

270.

Heap sort is faster than Shell sort.(a) true(b) falseThe question was posed to me during an interview.Question is taken from Heapsort topic in section Sorting of Data Structures & Algorithms II

Answer»

Correct option is (B) false

Best EXPLANATION: HEAP sort is slower than Shell sort because Shell sort uses Sedgewick’s increment sequence.

271.

In what time can a binary heap be built?(a) O(N)(b) O(N log N)(c) O(log N)(d) O(N^2)I got this question in an interview.The doubt is from Heapsort in section Sorting of Data Structures & Algorithms II

Answer»

The CORRECT answer is (a) O(N)

The best I can explain: The BASIC STRATEGY is to build a binary heap of N ELEMENTS which takes O(N) TIME.

272.

On which algorithm is heap sort based on?(a) Fibonacci heap(b) Binary tree(c) Priority queue(d) FIFOThis question was posed to me during an online interview.I'd like to ask this question from Heapsort in chapter Sorting of Data Structures & Algorithms II

Answer»

The correct OPTION is (C) Priority QUEUE

The best explanation: Heap sort is based on the algorithm of priority queue and it gives the best sorting TIME.

273.

Which of the following is true?(a) Shell sort’s passes completely sort the elements before going on to the next-smallest gap while Comb sort’s passes do not completely sort the elements(b) Shell sort’s passes do not completely sort the elements before going on to the next-smallest gap like in Comb sort(c) Comb sort’s passes completely sort the elements before going on to the next-smallest gap like in Shell sort(d) Shell sort’s passes do not completely sort the elements before going on to the next-smallest gap while Comb sort’s passes completely sort the elementsThis question was addressed to me in unit test.Origin of the question is Shell sort in division Sorting of Data Structures & Algorithms II

Answer»

The CORRECT CHOICE is (a) Shell sort’s passes completely sort the ELEMENTS before going on to the next-smallest gap while Comb sort’s passes do not completely sort the elements

Explanation: Both Shell sort and Comb sort have repeated sorting passes with DECREASING gaps. Unlike Comb sort, in Shell sort the array is sorted completely in each pass before going on to the next-smallest gap.

274.

Shell sort is more efficient than insertion sort if the length of input arrays is small.(a) True(b) FalseI had been asked this question in homework.The question is from Shell sort topic in portion Sorting of Data Structures & Algorithms II

Answer»

The correct answer is (b) False

The best I can explain: Insertion sort is more EFFICIENT than SHELL sort if the length of array is SMALL because insertion sort is QUITE SIMPLE to program and involve very few actions other than comparisons and replacements on each pass.

275.

Records R1, R2, R3,.. RNwith keys K1, K2, K3,.. KNare said to be h-ordered, if ________(a) Ki

Answer»

Correct option is (d) Ki <= Ki+hfor 1<= i <= N-h

Best EXPLANATION: Records are h-orderedif every hth ELEMENT (STARTING anywhere) yields a sorted array. Therefore, given records with keys K1, K2, K3,.. KNare said to be h-ordered, if Ki <= Ki+hfor 1<= i <= N-h.

276.

If Hibbard increments (h1= 1, h2= 3, h3= 7, …, hk = 2^k–1) are used in a Shell sort implementation, then the best case time complexity will be ________(a) O(nlogn)(b) O(n)(c) O(n^2)(d) O(logn)The question was asked in a national level competition.This interesting question is from Shell sort topic in portion Sorting of Data Structures & Algorithms II

Answer»

The correct CHOICE is (a) O(nlogn)

Explanation: The best case occurs when the array is already sorted. In best case the number of comparison for each of the increments-based insertion sorts is equal to length of array.

Here 2k –1 < n, where n is the number of records. So K < log(n+1), thus the sorting time in best case is LESS the n * log(n+1). Therefore best case time COMPLEXITY is O(nlogn).

277.

An array that is first 7-sorted, then 5-sorted becomes _________(a) 7-ordered(b) 5-ordered(c) both 2-ordered and 5-ordered(d) both 7-ordered and 5-orderedThis question was addressed to me in an online quiz.My question is from Shell sort in division Sorting of Data Structures & Algorithms II

Answer»

The correct OPTION is (d) both 7-ordered and 5-ordered

The BEST explanation: An array that is 7-sorted, BECOMES 7-ordered. And an array that is 5-sorted, becomes 5-ordered. If k-ordered array is h-sorted, it REMAINS k-ordered. THUS, an array that is first 7-sorted, then 5-sorted becomes both 7-ordered and 5-ordered.

278.

Shell sort is an improvement on ____(a) insertion sort(b) selection sort(c) binary tree sort(d) quick sortThis question was posed to me in a job interview.Question is taken from Shell sort in section Sorting of Data Structures & Algorithms II

Answer»

Right choice is (a) insertion sort

The best explanation: Shell sort is an improvement on insertion sort that allows the EXCHANGE of ELEMENTS that are far apart. Shell sort algorithm SORTS separate sub-arrays of the original input array. These sub-arrays contains EVERY hth element of the original array.

279.

Shell sort is applied on the elements 27 59 49 37 15 90 81 39 and the chosen decreasing sequence of increments is (5,3,1). The result after the first iteration will be(a) 27 59 49 37 15 90 81 39(b) 27 59 37 49 15 90 81 39(c) 27 59 39 37 15 90 81 49(d) 15 59 49 37 27 90 81 39This question was posed to me during a job interview.The origin of the question is Shell sort in portion Sorting of Data Structures & Algorithms II

Answer»

Right ANSWER is (c) 27 59 39 37 15 90 81 49

Easiest EXPLANATION - GIVEN elements 27 59 49 37 15 90 81 39,

First Iteration (span = 5):

So, the SEQUENCE after first iteration will be, 27 59 39 37 15 90 81 49.

280.

Statement 1: Shell sort is a stable sorting algorithm.Statement 2: Shell sort is an in-place sorting algorithm.(a) Both statements are true(b) Statement 2 is true but statement 1 is false(c) Statement 2 is false but statement 1 is true(d) Both statements are falseThe question was posed to me in unit test.This is a very interesting question from Shell sort in portion Sorting of Data Structures & Algorithms II

Answer»

The correct option is (b) Statement 2 is true but statement 1 is false

The BEST explanation: In Shell sort, the relative order of elements with EQUAL values MAY change. THEREFORE, it is not a stable sorting algorithm. Shell sort is an in-place sorting algorithm as it requires O(1) auxiliary SPACE.

281.

What is the worst case analysis of Shell sort using Sedgewick’s increments?(a) O(N^2)(b) O(N^3/2)(c) O(N^4/3)(d) O(N^5/4)This question was addressed to me in homework.Question is taken from Shell sort in portion Sorting of Data Structures & Algorithms II

Answer» CORRECT choice is (C) O(N^4/3)

Explanation: The worst case analysis of Shell SORT using Sedgewick’s increments is mathematically calculated to be O(N^4/3).
282.

What is the worst case analysis of shell sort using Shell’s increments?(a) O(N)(b) O(N^2)(c) O(N^1/2)(d) O(N^3/2)I got this question in semester exam.This key question is from Shell sort in chapter Sorting of Data Structures & Algorithms II

Answer»

Right option is (b) O(N^2)

The EXPLANATION is: The WORST case ANALYSIS is mathematically found to be O(N^2). The proof is RATHER complicated.

283.

What is the general form of Shell’s increments?(a) 1,2,3,…,n(b) 1,3,7,….,2k-1(c) 1,3,5,7,….,k-1(d) 1,5,10,15,…, k-1I have been asked this question by my college professor while I was bunking the class.Query is from Shell sort topic in division Sorting of Data Structures & Algorithms II

Answer»

Correct choice is (b) 1,3,7,….,2k-1

Easy explanation - SHELL’s increments are of the form 1,3,7,….,2k-1. The KEY difference is that the consecutive elements have no COMMON FACTORS.

284.

What is the worst case running time of shell sort using Hibbard’s increments?(a) O(N)(b) O(N^2)(c) O(N^1/2)(d) O(N^3/2)The question was posed to me during an interview.Question is from Shell sort in section Sorting of Data Structures & Algorithms II

Answer»

Correct answer is (d) O(N^3/2)

Explanation: Mathematically, the LOWER bound ANALYSIS for SHELL sort using Hibbard’s increments is O(N^3/2).

285.

On how many increment sequences does the worst case analysis of shell sort depends?(a) one(b) two(c) three(d) fourI have been asked this question in examination.I'd like to ask this question from Shell sort topic in section Sorting of Data Structures & Algorithms II

Answer» CORRECT choice is (C) three

The explanation is: The WORST case analysis of shell sort depends on two increment sequences- using Shell’s increments, Sedgewick’s and HIBBARD’s increments.
286.

Why is Shell sort called as a generalization of Insertion sort?(a) Shell sort allows an exchange of far items whereas insertion sort moves elements by one position(b) Improved lower bound analysis(c) Insertion is more efficient than any other algorithms(d) Shell sort performs internal sortingThis question was addressed to me in an interview for internship.My doubt stems from Shell sort topic in chapter Sorting of Data Structures & Algorithms II

Answer»

Right option is (a) SHELL sort ALLOWS an exchange of far items WHEREAS INSERTION sort moves elements by one position

For explanation: Shell sort is an extension of insertion sort because it swaps elements at far distances and at a FASTER rate.

287.

Which of the following sorting algorithms is closely related to shell sort?(a) Selection sort(b) Merge sort(c) Insertion sort(d) Bucket sortI have been asked this question during an interview for a job.I need to ask this question from Shell sort topic in chapter Sorting of Data Structures & Algorithms II

Answer»

The CORRECT CHOICE is (c) Insertion sort

To explain: Shell sort performs an insertion sort on hk independent ARRAYS. It is mainly a variation of insertion sort.

288.

Shell sort uses a sequence called a incrementing sequence to sort the elements.(a) True(b) FalseI got this question by my college director while I was bunking the class.I'd like to ask this question from Shell sort in portion Sorting of Data Structures & Algorithms II

Answer»

The correct CHOICE is (a) True

The best I can explain: Shell sort uses an INCREMENT SEQUENCE h1, h2, h3… and this sequence will WORK as long as h1=1.

289.

Shell sort algorithm is an example of?(a) External sorting(b) Internal sorting(c) In-place sorting(d) Bottom-up sortingI have been asked this question in semester exam.The doubt is from Shell sort in division Sorting of Data Structures & Algorithms II

Answer»

Right OPTION is (b) Internal sorting

For EXPLANATION: Shell SORT is an example of internal sorting because sorting of elements is done internally using an ARRAY.

290.

Shell sort algorithm is the first algorithm to break the quadratic time barrier.(a) True(b) FalseThe question was posed to me during an online exam.This interesting question is from Shell sort in section Sorting of Data Structures & Algorithms II

Answer»

The correct OPTION is (a) True

The best explanation: Shell sort broke the quadratic time barrier as it WORKS by COMPARING elements that are DISTANT.

291.

Who invented the shell sort algorithm?(a) John Von Neumann(b) Donald Shell(c) Tony Hoare(d) Alan ShellI had been asked this question in an online interview.This interesting question is from Shell sort in chapter Sorting of Data Structures & Algorithms II

Answer»

The correct option is (b) Donald Shell

The best explanation: Shell sort algorithm is invented by Donald shell. MERGE sort is invented by John Von NEUMANN. Quick sort is invented by TONY Hoare.

292.

The worst case running time of shell sort, using Shell’s increments is?(a) O(N)(b) O(N log N)(c) O(log N)(d) O(N^2)I got this question by my school teacher while I was bunking the class.This interesting question is from Shell sort in portion Sorting of Data Structures & Algorithms II

Answer» RIGHT option is (d) O(N^2)

The EXPLANATION is: The LOWER bound of a shell sort algorithm is mathematically found to be O(N^2).
293.

What is the other name for a shell sort algorithm?(a) Diminishing increment sort(b) Diminishing decrement sort(c) Insertion sort(d) Selection sortThe question was asked in an interview.Enquiry is from Shell sort in portion Sorting of Data Structures & Algorithms II

Answer»

The correct choice is (a) Diminishing increment sort

Easy EXPLANATION - The other name for a shell sort algorithm is diminishing DECREMENT sort as the DISTANCE between COMPARISONS decreases as the algorithm runs until the LAST phase.

294.

Quick sort uses which of the following method to implement sorting?(a) merging(b) partitioning(c) selection(d) exchangingI have been asked this question during an interview.Enquiry is from Sorting topic in section Sorting of Data Structures & Algorithms II

Answer» RIGHT answer is (b) PARTITIONING

Explanation: Quick sort MAKES partitions of the input array about the pivot in order to IMPLEMENT sorting. Thus its METHOD of sorting is called partitioning.
295.

What is the average time complexity of the median of three quick sort?(a) O(n log n)(b) O(n^2)(c) O(n^2 log n)(d) O(n log n^2)I have been asked this question by my college professor while I was bunking the class.The above asked question is from Sorting in section Sorting of Data Structures & Algorithms II

Answer»

Correct choice is (a) O(n LOG n)

To EXPLAIN: The average case time COMPLEXITY of median of three quick SORT is the same as that of a standard quick sort as randomized quick sort only helps in PREVENTING the worst case. It is equal to O(n log n).

296.

What is the auxiliary space complexity of a median of three quick sort?(a) O(1)(b) O(n)(c) O(log n)(d) O(n log n)I got this question in homework.Question is from Sorting topic in section Sorting of Data Structures & Algorithms II

Answer»

The CORRECT option is (c) O(log n)

The explanation is: Auxiliary space complexity of median of three QUICK sort is O(log n) which is used for STORING call stack formed due to recursion. NOTE that the algorithms with space complexity as O(log n) also qualifies as in place algorithms as the value of log n is CLOSE to 1.

297.

What is the purpose of using a median of three quick sort over standard quick sort?(a) so as to avoid worst case time complexity(b) so as to avoid worst case space complexity(c) to improve accuracy of output(d) to improve average case time complexityI have been asked this question in an interview.This is a very interesting question from Sorting topic in portion Sorting of Data Structures & Algorithms II

Answer» CORRECT option is (a) so as to avoid worst case time complexity

The BEST I can explain: Median of THREE quick sort helps in avoiding the worst case time complexity of O(n^2) which occurs in case when the input array is already sorted. However, the AVERAGE case and best case time complexities remain UNALTERED.
298.

What is the median of three techniques in quick sort?(a) quick sort with random partitions(b) quick sort with random choice of pivot(c) choosing median element as pivot(d) choosing median of first, last and middle element as pivotThe question was asked at a job interview.The query is from Sorting topic in chapter Sorting of Data Structures & Algorithms II

Answer»

The correct answer is (d) choosing median of FIRST, last and middle element as pivot

Easy explanation - In the median of three TECHNIQUE the median of first, last and middle element is chosen as the pivot. It is done so as to avoid the worst CASE of quick sort in which the TIME complexity shoots to O(n^2).

299.

Quick sort uses which of the following algorithm to implement sorting?(a) backtracking(b) greedy algorithm(c) divide and conquer(d) dynamic programmingI had been asked this question in examination.My question is from Sorting topic in portion Sorting of Data Structures & Algorithms II

Answer»

The CORRECT option is (C) divide and CONQUER

Best explanation: Quick SORT uses the technique of divide and conquer in order to sort a given array. It divides the array into two parts about the pivot and then applies quick sort to both the parts.

300.

Randomized quick sort is an in place sort.(a) true(b) falseI have been asked this question during an interview.My question is taken from Sorting in division Sorting of Data Structures & Algorithms II

Answer»

The correct choice is (a) true

Explanation: In-place algorithms REQUIRES CONSTANT or very less auxiliary space. Quick sort qualifies as an in place sorting algorithm as it has a very low auxiliary space requirement of O(LOG N).