People still look at you weird, but it's like, 'All right,he's disabled now, but it's kind of OK now.'" Matthew Sapolin is commissioner of the Mayor's Office for People with Disabilities, and he is blind.
VOA: special.2010.07.28
OK. The next largest element has to end up in the second last spot. Et cetera. All right, so it's called bubble sort because it does this bubbling up until it gets there.
好的,下一个最大元素又,能跑到倒数第二的位置,等等如此,好的,这称为冒泡排序,因为这个泡泡一直冒到他自己的位置。
OK, let me comment this out, and let's look at this next little piece of code. All right.
好,让我添加一点注释,然后让我们看看,下面的一些代码,好。
All right. OK, looks like we got the majority, which is a good start, but we having discrepancy on what people are thinking.
好的,OK,看来大部分人都做对了,这是个不错的开始,但还有一部分人的答案有分歧。
OK, any questions? All right, so we've described the system with these properties.
好,有没有问题?,好的,我们已经用这些性质描述了系统,这些性质。
OK? All right. x 3, as you can see right here, does exactly that.
你们可以看到,就是这么做的对不对?
All right, let me just go through one numerical example of a calorimetry calculation, OK.
好,让我们来做一个量热,法计算的例子,我不会把所有的。
OK, here we go, here we go, you see, I'm doing it down here, I can't see it, does that-- ah, I hear his sighs of relief, OK, good. There we go. Better. All right.
好,我们开始,大家可以看到,我在这里写这个程序,我看不见,这是不是-啊,我听到大家放松的叹气了,好,让我们开始吧,好多了,好。
OK, All right, so these are the thermodynamic quantities that you're familiar with already.
好,这些是你们已经,熟悉了的热力学量,让我们很快地。
OK, good. This might be our all-time high, 89% got this right. This is great.
好的,很好这可能是我们上课以来正确率最高的一次,89%,的同学都做对了,这太棒了。
OK. So to do this, we're going to have to do a couple of things. All right, the first one is, what do we mean by input size?
好,为了实现这种方法我们,有些事情要做,第一件事情就是,当我们说到输入的大小的时候代表了什么呢?
OK. All right, let me show you one other tool that I want to use. Which is, I've written that piece of code, I ought to check it. Well, I could just run it, but another useful thing to do is, I'm, especially as I want to debug these things, is to simulate that code.
好,那么,让我给大家讲下,我想用的另外一个工具吧,也就是,我已经写好了这一块代码,我应该去检查检查,那么我可以去运行它,但是特别是当我想要调试代码的时候。
OK cool All right, a couple. OK, cool.
有几个。
Right there. All right, we'll try this again. OK.
有人要么?你么?谢谢,顺便说一句。
b OK. In this example I'd use b. All right, as b get-- b is the thing that's changing as I go along here, but it could be things like, how many elements are there in a list if the input is a list, could be how many digits are there in a string if the input's a string, it could be the size of the integer as we go along. All right.?
好,在这个例子里我会用,因为b是一直在变的东西,但是也可能是如下情况:,如果输入是数组的话,变化的就是数组的元素数,如果输入是字符串的话,变化的就是字符串的长度,如果是integer的话,可能就是这个数的大小,对不对?
应用推荐