There is a big difference between some of the plots, so. So some plots have been separated to clarify, with the existence of the original one that combines all the sorting algorithms in the beginning of each comparison. We compared the time with the input size and then did the same between number of comparisons with the input size.
By referring to the above graphs, we can clearly conclude that there is a relationship between the input size, number of comparisons, and execution time for all the sorting algorithms mentioned (insertion sort, merge sort, heap sort, quick sort) in their worst cases. We can express the relationship as an incremental relationship as the larger the input, the higher the number of comparisons you get, leading to a longer running time. andAnd as a conclusion, we can consider the number of comparisons as a good predictor of execution time.
The text above was approved for publishing by the original author.
Previous
     
Next
받은편지함으로 가서 저희가 보낸 확인 링크를 눌러서 교정본을 받으세요. 더 많은 이메일을 교정받고 싶으시면:
또는