Computer Science, asked by sirishasowmya29, 1 year ago

a programmer writes a sorting algorithm that takes different amount of time to sort two different lists of equal size.what is the possible difference between the two lists​

Answers

Answered by nouser71
42

Answer:

The algorithm takes different amount of time to sort two different lists of equal size. What Is the possible difference between the two lists? The ordering of numbers with respect to the magnitude in the two list has different properties.

Answered by Anonymous
26

The possible difference in sorting time between the two lists of equal size is the arrangement of elements present in the lists due to which the algorithms will have different time complexities for both the lists.

For example:

  • List 1 is already sorted.
  • List 1 is half sorted in comparison to List 2.
  • One list can be the best case scenario while the other can be the worst case scenario for that same algorithm.

Similar questions