|
|
|
|
|
by phkahler
1453 days ago
|
|
The largest number is at position 1 after the first pass of the inner j loop. In fact it's at the ith position after each completion of the j loop, and it serves to separate the sorted and unsorted parts of the array. Beyond that it's just inserting the ith element into the list by finding its place and shifting everything over one position. |
|