So we've seen one example of this, this idea of walking through all the integers looking for the square root.
现在计算机速度很快了,我可以把这个数字设的更大点,计算机会去很快的做这个事情。
I thought London gives me enough to do for the next four years while I am studying to have a life.
我觉得在我学会在这里生活的时候,伦敦给予了我足够在未来四年里可以做的事情。
Thing I've got a little procedure that could do that, but you know the simplest thing I could do is to say well, gee, wait a minute, why don't I just check to see if these are the same thing?
这两个点是同一个点么?,我已经写了一小块代码,可以提供这个功能,但是你知道的我可以做的,最简单的事情就是说好,嗯?,等等,我为什么不直接去看看,这两个东西相等不相等呢?
Could I do more for the ultimate good of the slave population by holding or emancipating what I own?
我是否可以为奴隶的最终利益做的更多,是继续拥有他们,还是解放他们呢
And from there, I go to... saying well, what can we do in terms of global poverty?
由此,我想到,我们可以为全球的贫困问题做些什么呢?
After logging into the course's website, you'll appear on the top left-hand corner as I just did with your actual names that we know exactly who we're working with and then what you can do is raise your hand sort to speak.
登录课程网站之后,你将被显示在,左上角,通过你们的真实名字,我可以知道我到底是在跟谁一起工作,然后你们可以做的是举手来回答问题。
Because doing that allows me to explain certain things.
因为那样做使我可以解释特定的现象
Therefore, I can do what they did.
因此,我可以做他们做的事情
You can call your broker and say, I'd like to short stock number one and what the broker will do is borrow the shares on your behalf and sell them and then you own negative shares.
你可以打电话给你的经纪人说,我要做空一号股票,经纪人就会在你的名下赊入这些股票,然后卖掉,这样你就拥有数量为负的股票了。
As we do these little clicker poll things you can tell me if you find it helpful or not, then we can decide how to continue --whether to continue them in the future.
我们用表决器做这个小测试的同时,大家可以告诉我你们觉得这有没有帮助,然后我们再决定以后是否继续用
and I used to play tennis here, and my friends take kids to the pool. There's so much to do here.
我过去常来这里打网球,我的朋友会带孩子去游泳池。在这儿可以做的事情太多了。
And, this is how I'm doing now in relationship to what we're currently discussing or evaluating or experiencing.
这也可以表达我手头正在做的事情与我们正在讨论、评价或者经历的事情之间的联系。
There's a lot of, you know, surfing, water sports, skating, stuff like that that I like to do.
可以经常,你知道,可以冲浪、水上运动、滑冰,我喜欢做的那些事。
Couple of things. One, all my favorite activities that I love doing are available here.
好几点呢。第一,我可以在这里做我最喜欢的活动。
Or like I said, you can directly reference what you do not wish to do.
或者像我说的那样,你可以直接表态你不想做某事。
I hope that she can continue making the right decisions, be a good person.
我希望她可以一直做正确的决定,做一个好人。
and that, I did some preparation for, like, you know, they sell those books.
我为这个考试做了一些准备,你可以购买这方面的参考书。
that's still something really neat that I can do in my free time.
我在空闲的时间还可以做一些很有意义的事情。
So I love Central Park. There is so much to do down there.
所以我非常喜欢中央公园。在那儿可以做的事情太多了。
and enjoying the sunshine while I do that and talk to people.
当我做这件事的时候,可以和人聊天、享受阳光。
So let's step through this with a little more care And I keep saying, before we do it, - let's just actually try it out.
因此我会做做试验,我会去做一些实验性的输入,我可以输入。
Well, thus far, I haven't written any programs that themselves take any such arguments, and yet it turns out I can do exactly that.
到现在为止,我还没有写任何的,它们自己携带参数的程序,但是,我完全可以这样做。
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.
我可以用它来返回值,然后我可以在别的地方使用这些返回值,正是我做的--如果我回过头来,在高亮一下这个--在这部分计算内部。
This half, I'm gonna put my finger on the 1 and notice I can do the same thing.
这一半,指向1,注意到我可以做同样的比较。
Important lesson, so that there would be some predictability in the results and I would have some, if you will, smoke test for knowing whether or not I was getting, my code seemed to be working.
这很重要,因为这样我就可以预测,结果会是多少了,如果你愿意,我们可以做烟气试验,来看我的代码是否工作正常。
I don't have to go read what it printed out in the screen. This has returned a value that I can use. Because I could do a test to say, is this a return value? If it's not, I'll do something else with it. So the binding is still there, it simply doesn't print it out.
我不想读到屏幕中打印出来的这行字,程序返回过一个我能够使用的值,因为我可以做个小测试,来说明这是否是返回的值,如果不是,我可以做一些其它的事,而这个绑定依然在这儿,没有打印任何东西。
And my real answer is, go try it out, because obviously you can tell I frequently do this the wrong way and the TAs give me a hard time every time. John.
你可以,而我真正的答案是去试一试吧,因为很明显你可以发现我老是做错,而我的助教总是给我难堪,约翰。
Well, I can do the same thing.
好,我可以做同样的事情。
These are instances of a class, and associated with that class are a set of methods things that I can deal with.
但是Python的基本思想是相同的,这是一些一个类的实例,这个类关联了一个方法集,我可以做的一些操作。
应用推荐