Suppose that you have been running an unknown sorting algorithm. Out of curiosity, you once stopped the algorithm when it was part-way done and examined the partially sorted array. You discovered that the first K elements of the array were sorted into ascending order, but the remainder of the array was not ordered in any obvious manner.

Based on this, you guess that the sorting algorithm could likely be:

Shell's Sort

heapsort

quicksort

merge sort

insertion sort

Respuesta :

The sorting algorithm could likely be: insertion sort.

Insertion Sort

Explanation:

There are may sort is available in programming languages, in this situation  Insertion sort method is used. Here, in insertion sort, the array elements are compared with each other cells and find the smallest value from cells pushed front thus, forming a sorted ascending ordered array.

If we stop the algorithm midway, we would get a sorted array till where the iteration is stopped and the other elements are not sorted or ordered in any way. This sort is only used to find a small number from the array, thus it is easier sorting technique than others.

ACCESS MORE