In other words it doesn't just return when it finds one, it's going to run through all of them. All right?
但是它将会继续运行,换句话来说当它找到一个结果时,它不会立刻返回结果它会先遍历所有的内容?
Is it one basically? In which case, just return a copy the list. That's the simple case.
是最基本的情况吗?在这种情况下,仅仅返回一个列表的拷贝,这是简单的情况。
And just return your awareness to your breath.
重新集中注意力到呼吸上。
What could I just return instead?
然而我可以返回什么?
So let me just return once again to the way in which sign systems are intelligible because lots of- there are going to be lots of moments in a course like this in which what we seem to be saying is that, "Oh, we can't know anything," or "We don't know what we know," or "How do we know what we know?"
现在让我们回到,怎样理解符号系统的话题上-,这个学期你们会有很多时候觉得,天哪,我们什么也认识不了“,或者,哎,我们其实并不了解我们以为理解的事“
I think they motivate a lot of what -I'm going to write a number of principles of behavioral finance down and just mention them briefly and then return to regulation.
我认为他们促进了这些...,我先写一些行为金融学的原理,只是先简单地过一遍,再回到市场监管
And then I'm going to just return the bigger of the two. Little bit complicated, but it's basically just implementing this decision tree.
我会计算总价值,然后我会返回两者中的较大值,有点小复杂,但是它就是按照这个决策树在运行。
I'm going to print here the list if we go into it, and print of the when we're done and then just return that.
注意接下我来我要做的事,运行到这里时会打印列表,并且当处理完成后会打印返回的列表。
So, I just return 1.
所以,我只是返回。
And one is the third element. And just return, it's done. It is a palindrome. That make sense.
完成,数组时回文的,这就对了,因为数组1a1从前面和从后面读都是一样的。
The prototype is just its return value, its name, and its arguments, if any.
原型就是他的返回值,它的名字,它的参数之类的。
So the first thing it does, price=0 is it says, if self dot price is 0, I'm just going to return.
所以它做的第一件事就是,如果self。,我就返回。
So this first little piece of code right here says, ok you give me 2 points, I'll create another 1 of these lists and I'll simply take the x, sorry I shouldn't say x, I'm going to assume it's the x, the x-values are the two points, add them together, just right there, the y-values, add them together and return that list.
好,为了来认识到这一点,让我们来看一个简单的小例子,在你们的课堂手册上,你可以看到我写了一个小程序,它假设我得到了,这些点中的一些,我想对它们做一些操作,例如我想把它们加到一起,那么这里的第一小片,代码的意思是,好给我两个点,我会再创建一个数组。
D-A-V-I-D Well, if I've got a five-letter word like D-A-V-I-D, well, that's like five bytes and yet we only have the ability thus far in this class to return one thing at a time I can't return five bytes to you, but wait a minute, those bytes by nature of a computer are just stored in RAM.
好的,如果有5个字母的单词,如,那是5个字节,我们只能返回一个东西,而不能返回5个字节,等一下,这些字节被计算机本能地,存储在内存中。
Now, less than is just, if you haven't used it before, it's just the operator you'd expect, it's comparing two things and it's going to return either true or false depending on whether the first argument is false less than the second argument.
现在,小于这个符号是,如果你之前没用过它的话,它就是你期望的那个运算符,它会比较两个独享,然后基于第一个参数是不是,小于第二个参数,返回true或者。
OK? You can take a quick look at it, a even with the wrong glasses on, it says if a 1 sorry, b is equal to 1, a I'm just going to return a.
你们可以快速的过一遍,它是这么写的:如果,对不起,是b等于,那么就直接返回。
X I'm passing an X, and yet I'm also assigning the return value to X. So just intuitively what's going to be the effect of this one line of code?
我传一个X,之后我把返回值赋值给,很明显,这一行代码,将会产生什么作用?
I can use that to return values, which I can then use elsewhere, which I did-- and if I just come back and highlight this-- inside of that computation.
我可以用它来返回值,然后我可以在别的地方使用这些返回值,正是我做的--如果我回过头来,在高亮一下这个--在这部分计算内部。
It says, well I'm going to print out first and last just so you can see it, and then I say, gee 2 if last minus first is less than 2, that is, if there's no more than two elements left in the list, then I can just check those two elements and return the answer.
然后它计算了尾点和开始点的差,如果小于2的话,也就是说数组中的元素小于等于,我对这两个元素进行比较,然后返回结果就可以了,否则的话,我们就去寻找中值点,注意它是怎么实现的,首先这个指向一个列表的开头。
this is perhaps the most interesting thing because it forces us to show the complexity, to see the complexity, of semiotic relationships: a red light, just to return to the Christian holiday, a red light on a Christmas tree.
现在我们讲到了一个耐人寻味论点,这个问题迫使我们要思考,符号系统之间复杂的联系:,当我们再圣诞节时看到红灯,圣诞树上的红灯。
So I might as well return the without i value I just computed.
所以我不妨返回除去i外,我刚算过的值。
Instead I'm going to be expecting the address of some int and the address of another int and thanks to this address I can literally find this address in RAM, do anything I want there, -- return and what I've just done is actually changed or mutate the values of those original variables.
我们所期望的是int型地址,和另外一个int型地址,幸亏这个地址,我可以找在RAM中找到它的地址,然后做我想做的事情,返回我处理后的东西,我可能改变了这些源变量。
应用推荐