And the last piece I want you to see here, and then I'll let you go is, notice now how that encapsulation, that binding things together has really helped me.
我想要的那么干净,最后一点要给大家讲的是,也就是下课前讲的一点,就是请注意这里是怎么封装的,也就是把东西绑定在一起。
And I really like how in California, no matter where you go, people are very friendly and real,
我很喜欢加州这一点,不管你走到哪里,人们都很友好,很真
And so with this example here, I thought I'd propose that we consider exactly how you'd go about tackling something like this.
有了这个例子,我想我们可以,考虑一下应该如何下手,解决这样的问题。
Go back over here and we're going to say isPalindrome isPalindrome. How did I actually spell this?
回到这里来,我们将要再说一下?
How do I sustain myself when things don't go the way I planned?"
当事情超出了我的预测,我该怎么继续下去?“
How should I go about doing that? How should I do that?
我应该如何着手呢
I can get this to show us how far up we are supposed to go, by placing it on some kind of grid here," and this is this--as I said before, the beginning of the first graph in the history of the West.
我可以通过将它放置在这样的网格中,来表明我们的声音应该有多高,而这就是,正如我以前所说,西方历史上最早的图示法
I don't know, I didn't go to business school so I'm not exactly sure how it works.
我不知道,我没在商学院上过学,所以我也不清楚它到底是怎样的。
He wasn't that widely read, I must admit, but it shows us how far pro-slavery could ultimately go.
我必须承认,他的作品流传不广,但他向人们展示了亲奴主义者可以走多远
Or when we ask ourselves, how will things go for me over the next couple of weeks ? if I go on vacation versus staying back here?
或者我们可以问自己,接下来几周事情会如何发展,如果我去度假而不是留在这里?
and whenever I go back to the East Coast, I'm kind of struck with how there's...
每当我回到东海岸,我都会震惊于……
So, that's kinetics -- how fast a reaction will go, and from the perspective of someone who's a biochemist, I'm interested in kinetics and enzyme kinetics, and thinking about molecules that catalyze reactions in the body.
所以这就是动力学,一个反应发生的有多快,从一个生物化学家的角度,我喜欢研究动力学,酶动力学。
No one has a clue on how I can go back from these to that?
难道没人能给出倒求出它们的方法吗
But basketball, I just find that how quickly they go across the floor,
但看篮球时,我会发现他们穿越球场的速度飞快,
We'll talk about how they work and we'll go over that quickly because I know most of you know something about how DNA what DNA is and how it works.
我们将讨论它们如何工作,我们讲的时侯会一带而过,因为我知道你们大多数人,知道一些关于DNA的知识,DNA是什么,它是如何工作的
If I want to try and decide how to tackle a problem in an iterative matter, here the steps I'm going to go through. First thing I'm going to do, is I'm going to choose a variable that's going to count.
但是这就是我对它的观点,如果我试着去以迭代的方式,解决一个问题的话,下面是我应该采取的步骤,第一件要做的事情。
How am I gonna go about writing a program?
怎么写呢?
And by that, I mean, not how much memory do I need to store the size of the input, it's really how much internal memory do I use up as I go through the computation?
需要占用多少内存,我意思并不是,存储输入需要多少内存,而是当我完成这个?
And let me go ahead and run-- how do I compile this?
继续运行,大家还记得怎么编译吗?
I've got to go to the first place, figure out how far over to skip, go to the next place, figure out how far over to skip, eventually I'll be out the door.
需要多长时间?,这太离谱了,因为我需要先去第一个元素,计算出下一个元素。
How do I go about that exercise?
如何找出纳什均衡呢
Now, efficiency is obviously an important consideration when you're designing code, although I have to admit, at least for me, I usually want to at least start initially with code that works, and then worry about how I might go back and come up with more efficient implementation.
现在,当你设计程序的时候效率,是不得不考虑的问题,虽然我必须承认,至少对我来说,我是先担心程序能不能运行,再去把它的效率优化的,我喜欢可靠点的东西。
How many times do I go through the loop?
那我执行了多少次循环呢?
Sorry? OK. You're doing the whole thing for me What's the complexity just of this inner loop m How many times do I go through that loop?
就这一块代码的,我执行了多少次这个循环?,次对不对?,here?,Just,this,piece。,我一会儿就会去得到你的答案的?
If I go back to that code from a moment ago, and I just rerun math3, notice how many places printed after the decimal point -- two?
如果刚才我回到那段代码中去,我们回到math3,请注意在小数点后面,会打印几位数呢--两位?
How far along do I have to go drop off a - c when I have slope -2b?
斜率-2b的线还要经过哪个横坐标呢
应用推荐