If you want to know something like when do you hit the ground, I think it's fairly clear what you have to do.
如果你想知道车子何时落地,我想你该做什么就很明显了
OK? Because what am I doing? It's called bubble sort because it's literally bubbling along, right?
明白了么?你要知道我在做什么,冒泡排序真的就像冒泡,对么?
I'm going to tort-- I'm going to make the font smaller so we can see more.
我们还没看到比较结果,好,你知道我要做什么了么?
Computing square root. I'm going to capture it in a piece of code, I'm going to be able to refer to it by a name, and I'm going to suppress the details, meaning inside of that computation, you don't need to know what it does. You just need to know, if I give it the right kind of input, it'll give me back an input that satisfies the contract that I set up.
比如计算平方根,我会用一段代码来说明,我将给它命名,并且忽略细节,意思就是在这一段计算过程中,你不用知道它做了什么,你只需知道,如果我进行了正确的输入,它将会给我符合条件的输出。
应用推荐