Why insertion sort is best algorithm for sorted or nearly sorted array?

Viewed 9533

So i guess its because it just compares A[k] and A[k-1], and does the implementation in one sweep but its still not clear. Can someone explain better. Thanks

4 Answers
Related