So in fact if I run this, ah, and save it, and it prints out odd.
因此实际上如果我运行这个,啊,先保存它,然后它输出奇数。
but everyone knows, like, which one's, ah... which societies exist and who is in them, just things like that.
但是每个人都知道这种社团的存在,也知道社团的成员是谁,这些事情都不是秘密。
Ah,says the soul theorist, Follow the soul--unless the soul splits, Shelly Kagan in which case neither of them is Shelly Kagan.
灵魂理论者说,跟随灵魂,除非灵魂分裂,那样他们就都不是。
In this case, it's cutting up from the bottom end, which makes sense because the thing I'm looking for is always bigger than the midpoint and then, I don't know, let's pick something in between. Somebody want-- ah, I keep doing that-- somebody like to give me a number?
排除元素,这是讲得通的,因为我总是找比中点大的元素,那让我们挑一个同,中点之间的元素吧,我再来试试,谁给我个数字吧,我知道你们想给我些其他东西?
so it's not always ah, in the library.
免得我整天都泡在图书馆里。
Chris? Ah, yeah, he lives in South Providence.
克里斯吗?好的。他住在南普罗维登斯。
And depending on the mood I'm in, I either congratulate them, or I say ah, you screwed up, huh? Then you had to fix it.
看起来他们挺为这事儿自豪的,我的回应得看我的情绪怎么样了,我可能会庆祝他们或者说,啊,你搞砸了。
Ah ha, split it in half.
啊哈,把它分成两半。
Ah-ha. Notice what-- where am I, here- notice what happened in this case.
啊哈,看见了什么?,在哪里呢,在这儿。
In binary search-- ah, there's that wonderful phrase, this is called a version of binary search just like you saw bin-- or bi-section methods, - when we were doing numerical things- in binary search, I need to keep track of the starting point and the ending point of the list I'm looking at.
就是当我们处理数字的时候,所称的二分检索,在二分法搜索中,我需要记录区间的开始点和尾点,初始化的时候就是-,问题输入的开始点和尾点,当我开始做测试的时候,我想要做的就是去取中值点。
And notice, by the way, if I do that, and I type sqrt and open the paren, ah-ha! It shows me what the creator, in this case actually I stole this from John so what Professor Guttag put up as his specification for this piece of code.
它需要什么养的输入和其它我想传达的信息,如果我这么做了,我将会到这里打上sqrt并且加上括号,啊哈!这里告诉我这段程序的创建者,事实上这是我是从约翰那里偷来的,所以也就是Guttag教授在它的。
应用推荐