Which of the following statements is TRUE about Quick Sort?
It always has a time complexity of O(n log n).
It is a stable sorting algorithm.
It performs poorly on already sorted arrays if the pivot selection is not optimized.
It is generally preferred over Merge Sort for arrays.
What is the primary data structure used in Heap Sort?
Binary Heap
Linked List
Queue
Stack
You want to search for a target value in a sorted array with millions of elements. Which algorithm would generally be the fastest?
Interpolation Search
Jump Search
Binary Search
Linear Search
What is the main challenge in implementing a circular array?
Handling the resizing of the array
Managing the wrap-around behavior correctly
Efficiently searching for elements in the array
Determining the starting index of the array
What is the time complexity of deleting a given value from an unsorted array in the worst case?
O(n)
O(1)
O(n log n)
O(log n)
Rotating an array by 'k' positions to the right means:
Sorting the array in descending order.
Reversing the entire array.
Shifting each element 'k' positions to the right.
Shifting each element 'k' positions to the left.
What is the time complexity of inserting an element into a Max Heap containing 'n' elements?
What is the time complexity of searching for a target value in a sorted array using binary search?
Which data structure is most suitable for implementing a sorted array with efficient insertion and deletion operations?
Array
In the context of searching algorithms, what does the term 'adaptive' refer to?
Algorithms that can handle unsorted data.
Algorithms that use divide-and-conquer techniques.
Algorithms that adjust their strategy based on previous search results.
Algorithms with a constant time complexity.