I'm thinking about a problem, I'm going to show you an example in a second, first thing I'm going to do is say, what is the thing that's going to change every time I run through the same set of code?
我要解决一个问题,我马上会让大家看一个例子,第一件我要做的事情就是,弄明白每次运行同样的指令集时,每次都会改变的东西是什么?
Everytime I've gone to go see a show, except for maybe once or twice,
大概只有一两次例外,每次我去看一场演出时,
I just go down the list selecting the smallest person at a time and then I repeat, repeat, repeat but when we actually did out the math or kind of reason through it, the running time, the asymptotic running time of bub-- of Selection Sort was also what?
只需要遍历列表,每次找出最小的元素,然后重复上述步骤,但从数学角度看,选择排序的时间复杂度,又是多少呢?
So, that's sort of the mathematically how we get to a, but we can also just look at the graph here, because every time we go one wavelength we can see that we're back in a maximum.
这是就我们得到a的数学,办法,但我们可以直接,从图上看,因为每次我们,经过一个波长,都回到一个最大值。
应用推荐