You are writing a program and want to use a divide and conquer method for sorting the data, a pivot point, and recursion. Which of the following algorithms would fit all the criteria?(1 point)

Responses

bubble sort
bubble sort

quick sort
quick sort

merge sort
merge sort

binary search

1 answer

The algorithm that fits all the criteria of using a divide and conquer method for sorting with a pivot point and recursion is quick sort.

  • Quick Sort: It divides the array into sub-arrays around a pivot element, recursively sorts the sub-arrays, and is a prime example of the divide and conquer strategy.

  • Merge Sort also uses divide and conquer but does not use a pivot; instead, it merges sorted sub-arrays.

  • Bubble Sort does not use divide and conquer and is not recursive.

  • Binary Search is not a sorting algorithm; rather, it is a search algorithm that requires a sorted array.

Therefore, the correct response is quick sort.