It adds the integers in order, so the list is already sorted at the end.
它将按顺序添加整数,因此在结束时已经给列表排好序。
This setting repositions all existing list items in sorted order.
本设置以排序顺序重新放置现有的所有列表项。
And then over to the bins where I keep finished work, sorted by diagram design, to see what I already have printed up and hopefully trim down the long list of what I'll need to print to order.
然后穿过我放成品,图表设计的箱子,去看看我已经印刷好的东西,并满心希望地整理长长的,需要印刷的清单。
Basic idea, before I even look at the code, is pretty simple. If I've got a list that is sorted, in let's call it, just in increasing order, and I haven't said what's in the list, could be numbers, could be other things, for now, we're going to just assume they're integers.
我们可以说基本的思想是很简单的,如果我有一个排好序的数组,让我们认为这个数组是递增的吧,我并没说数组里元素是什么,可能是数字,也可能是其他的东西,现在我们假设是integer类型的数字吧,最简单的方式就是这么做了:
应用推荐