And the first thing you do is ask is it an instance of some problem that other people have already solved?
而且你以前从没碰过这个问题,你首先要做的一件事就是问问自己,这是不是一个别人已经解决了的问题?
It depends on like, depends a little bit on like if you have time to take a class or so.
这要看,这有点要看你是不是有时间上课。
And in this case we're going to look at silicone, and we'll say if you can point out to me which requires the least amount of energy.
这次我们要做的是关于硅的,我们来看看大家是不是,能够为我指出那一项需要消耗的能量最少。
I think you should take the lab sometime, but I don't know how many semesters that you have to take.
我觉得你们应该是不是地去做几次实验,我不太清楚你们要上多少个学期的课
If I'm going to make insulin from this I have to know that I've got the introns spliced out correctly.
如果我要用这些来生成胰岛素,我就得知道是不是把内含子都准确剔除了
First, it's pointing to the beginning of the list, which initially might be down here at but after a while, might be part way through. And to that, I simply add a halfway point, and then I check.
列表中间的一个部分了,然后我求出列表的中值点,然后看看该点的值是不是等于目标值,如果是的话就完成了,如果不是的话,如果中位值大于我要找的目标值。
Put that all down and you pretty quickly see that, regardless whether the other guy rats you or not, you're better off ratting him out.
先放下手里的事,快速思考一下,不管那个家伙是不是坦白了,你最好要坦白
What you wanted--at least what I want, I invite you to ask yourself whether you want the same thing-- what I want is not just survival, but survival with the same personality.
你想要的,至少我想要的,你们也问问自己你们是不是想要这个-,我想要的不仅仅是存活,而是带有同样的人格存活。
You need to know if it's an equilibrium, and you also need to know how many components you have in your system So, a glass of ice water with an ice cube in it, which is a heterogeneous system, has only one component, which is water, H2O.
要知道它是不是平衡的,你还需要知道,你的系统中有多少组分,一杯放了冰块的水,虽然它是个非均匀系统,但它只有一种组分,那就是水。
But when you start writing programs, especially when we get to web-based stuff where you want -- to check the user's input -- is it valid, is it an email address, -- and all these different scenarios -- it's actually often useful to be able to just enumerate them or rattle them off using this switching construct instead.
但是当你看是写程序时,特别是当我们,使用基于网络的东西,你想要,检查用户的输入-,它是合法的吗?它是不是一个电子邮箱地址?,所有的这些场景-,实际上它常常是有用的,当你用枚举结构列举它们,或者用它来快速地来说出它们。
It all sort of depends on how you hit it off with somebody, whether there's a spark.
这要看你是不是跟那个人合得来,能不能擦出火花。
Is this something you always grow up saying, "I wanna be a philosopher when I grow up."
您小的时候是不是常常说,“等我长大了,我要做一个哲学家“
Now that may interest you at the moment, or what you may want to do is to get a printout of the whole day after that.
是不是很吸引人,你可能会想要,把接下来这一整天的结果打印出来
But whether that's an aberration, or that it's a new trend is still too early to say right now whether we're a new growing trend or not.
但究竟这是意外现象,还是一股新趋势,要下定论现在还为时尚早,我们还无法确定这是不是新趋势。
I don't know, whether you guys are going to hang out all the time
你是不是要在外面闲逛而给室友带来不便,
So, then we go to thermodynamics and chemical equilibrium, and this is really about chemical reactions -- weather a reaction will go, will it be spontaneous, if there an equilibrium, what direction will the reaction be shifted in.
然后我们要讲到热力学和化学平衡,这都和化学反应有关,一个反应是否能发生,是不是能自发反应,如果存在化学平衡,它会朝什么方向移动。
I was about to get them the wrong way around.
我是不是要把你们弄糊涂了
When I think about what I want-- and I'm just going to invite you to,each one of you, to ask yourself what is it that you want, what matters to you in survival?
我思考自己想要什么这个问题时-,我也请你们每个人都,问问自己这是不是你们想要的,你们想要存活是为了什么?
And the last thing we do for any of our structures to check them and figure out are these valid or not valid, are these good Lewis structures is to check the formal charge.
而为了检验任何一个结构是否有效,看它们是不是好的路易斯结构,我们要做的最后一件事就是检查形式电荷。
The answer lies in, if only we could know is that the same hunk of stuff or not.
要知道答案,我们就要,我们就要知道是不是同一块东西。
And that you might look at, for example, that first example, and say, man by this stage it was already sorted, yet it had to go through and check that the third element was in the right place, and then the fourth and then the fifth and then the six.
你可能会去看看例如第一个例子,然后要抱怨,到这里,它已经是排好序的了,但他还是得去遍历查看,第三个元素是不是在正确的位置,然后第四个,第五个,第六个。
The other thing I wanted to mention and I'm not sure if the exhibit's still there.
另外一个我想要指出的事情就是,我不确定它是不是还在展出。
What else might we want to see, to see if we got things working properly?
我们还希望看到什么呢,要看看我们的程序是不是正确运行的?
And those are two things that you'd like to do with every looping construct you write: you'd like to be able to assure yourself that they will always terminate, and then the second thing you'd like to do, is to assure yourself that it does give you back a reasonable answer.
就是现在我有了能去检查程序,是不是做了正确的操作的能力:,这就是你们在写每个循环程序的时候,都要注意的两个事情:,第一件事情是要确保程序可以终结,第二件你要做的事情,就是要确保程序返回了正确的答案。
So I'm going to check to see if- really can't read that thing, let me do it this way-- right, I'm going to increase the number of compares, and I'm going to check to say, is the thing I'm looking for at the i'th spot in the list?
让我们这样做吧-好-,我会去增加比较次数的计数器,然后去看看在第i处的元素,是不是我要找的呢?,这里s的意思就是,给定数组的?
Some people like to use shallow and deep, object and value, but they're talking about the same thing, which is it the same object or is it the same, in this case, set of values, depending on what you want to define as you use it.
有些人喜欢用对象相等值相等,但是它们是同一件东西,也就是是不是同一个对象,或者是不是同样的,在这个例子中,是同样的值集合,这取决于当你使用它的时候,想要怎么来定义它。
Now I am going to take some time to think about whether or not harmony is a good analogy, because I actually think it is a good analogy.
现在我要花点时间思考,和声是不是个好的类比,因为实际上我觉得它是个好的类比。
So if this is true do something else, true otherwise test and see if this is true, do something else, as many as I like followed by the end.
因此如果结果为true那么做一些操作,否则的话再看看这个表达式的值是不是,如果是的话做另外一些操作,我想要多少后面就可以跟多少。
We'll test our hypothesis, or at least examine it again see if it's, in some sense, repeatable.
我们要测试我们的假设或者至少再检查一下,让我们看看它的结果是不是可以接受的。
应用推荐