The list tells what services they offer and how much they want to be paid.
VOA: special.2009.02.02
So in this case, one of the standard ways to do this, is to use what's called a linked list.
标准的处理方法是使用链表,我接下来也准备这么做。
So it's certainly at least linear in the length of the list. For each starting point, what do I do?
它至少是线性的计算列表的长度,每次到了循环开始的点?
Coast guard officials said it is still not clear what caused the ferry to list and said an investigation will be conducted as soon as rescue operations are over.
VOA: standard.2009.09.06
I think this is as good list so let's go and think about what might be a little bit more challenging.
我想上面这些都是很好的例子,接下来我们思考一些更有挑战的问题
And what this means is that any theory of language use and language comprehension cannot simply appeal to a list.
这也就意味着,任何语言使用和语言理解的理论,都无法列出一份句子的清单
But what you should be able to do is take a look at a list of answers for what we're saying z effective might be, and determining which ones are possible versus which ones are not possible.
但是你们应该能够做到的,是看一下这个可能的,有效电荷量的答案列表,并且确定哪些是可能的,哪些是不可能的。
If you didn't accept Marcion's canon,his list, what was going to be your list?
如果你不接受马吉安的正典书目,那你的书目是什么?
I can now just blindly copy what remains in the previous list here.
我现在就可以直接将,前面列表中的元素拷贝到这儿。
It's a list of what you have to know about a system right now.
它包含系统当前的全部必要信息
Now, we might argue about what's the exact best list of those abilities.
我们可以探究一下,人具体有哪些能力
Now, what do you suppose was the most expensive item on that list?
你们觉得清单里的哪一项最贵?
Is not any so-called list of great thinkers ? or great texts likely to be simply arbitrary and tell us more about what such a ! list excludes than what it includes?
这种所谓的伟大思想家,或巨著清单不会太过于武断吗,它告诉我们的应是,遗漏多于涵蕴吧?
Well the fact is it could be hundreds of foods in the American food supply, and what's noteworthy about this particular list of ingredients, is that it's fifty-six entries long; fifty-six things in this particular food and we defined it as food.
实际上,答案可以是,几百种美国食品,值得注意的是,这张配料单,居然包含了五十六种配料,这种由五十六种物质构成的东西,而我们还将它定义为食品
I look at the rest of the list to decide what's the element to swap into the next place.
我会查看列表剩下的部分,来看看需要交换哪个元素。
If I do this, try and get the 10th element of a list that's only eight long. I get what looks like an error, but it's actually throwing an exception.
如果我来这么做,试着去取长度为8的列表的第十个元素,我貌似能得到一个错误。
All right? I don't care what's in there, but just assume that's my list. And just to remind you, on your handout, and there it is on the screen, I'm going to bring it back up, there's the little binary search algorithm.
好,我不管列表里是什么,就假定那是一个列表,要提醒你们的是,在你们的讲义上和屏幕上,有一个简单的二分查找算法。
Notice what the canon list eventually have.
看看最终的正典书目有什么。
I've added the ability to have more complex data structures here. But I dropped a hint in the first lecture about what you could computer with things. In fact if you think for a second about that list, you could ask what can I compute with just that set of constructs?
我添加了使用更复杂的数据结构的能力,但是我在第一节课给大家了了一个,关于你可以用什么来做计算的暗示,实际上如果你思考,这个列表一会儿的话,你会问我可以用?
A little later we'll turn to the question of, well, if hedonism is not the right story, ? what else belongs on the list, or is it the right story?
过会,我们会转向探讨…,如果享乐主义是错误理论,名单上还有什么?它是不是正确的理论?
There's a partial list that's shown here, starting the top of the list with smallpox, and that's what we're going to spend most of the time talking about today.
这是列表的一部分,表上第一个是天花疫苗,今天我们要用大部分时间讨论它
Let's check it out. I've written a little bit of a test script here, so if we test cell sort, and I've written this so that it's going to print out what the list is at the end of each round, OK.
我们来检查检查,我写了一个小测试脚本,我写这个脚本来测试单元排序,它能够打印出每一轮结束后,链表的是什么样子的。
And as a consequence, access time in the list is constant, which is what I want.
这会占用一些额外的空间,回到问题本身,这么做的话,读取数组的时间就变成常量了。
What am I doing? I'm creating a list with just that special symbol none in it.
我在做什么?,我只是在创建一个,有着特殊标记。
Since that object is itself a list, what I get is a list of lists.
因为这个对象本身就是个数组,因此我得到了一个包含数组的数组。
You find some way of systematically going through the list. Yet, I often see people, when they're debugging, proceeding at what, to me, looks almost like a random fashion of looking for the bug.
是不是目标元素,我们有一种系统化的,遍历数组的方法,然后我经常看到,有些人调试的时候。
Well let's see. My fall back is, I could just do linear search, walk down the list one at a time, just comparing those things. OK. So that's sort of my base. But what if I wanted, you know, how do I want to get to that sorted list? All right?
我只能做线性搜索了,一次遍历一遍列表,一个一个比较,但如果我想要,那怎样得到有序的列表呢?,现在的一个问题是,我们排序之前?
Takes in a list. What does it say to do?
这段代码要做什么?
That isn't there. So it couldn't do it, so instead that's what append is for, is to stick things on to the end of the list.
也就是说不存在,因此没法进行指向绑定的,更改,因此这个命令并不像append那样,会在list的最后添加元素。
So to just preface what we're going to do next time, what would happen if I wanted to do sort, and rather than in sorting the entire list at once, I broke it into pieces, and sorted the pieces, and then just figured out a very efficient way to bring those two pieces and merge them back together again?
所以为了引导下一次,我们要讲的内容,如果我想做排序,而且不是一次吧整个列表排完,会发生什么,我把它拆成小的列表,然后把各个小列表排序,接着用高效的方法再把小的列表?
应用推荐