Third thing to notice is, there's a flow of control. The order which these things are going to happen.
第三件事情就是,我有一个控制流,这些事情有个要做的先后顺序。
Just something that's just for you. That you can do to kind of honor yourself.
就只为自己。做这些事情是为了犒劳一下自己。
One of the things they can do is suck, and these babies would suck on a pacifier to hear French.
他们能做的事情之一就是吮吸,这些婴儿听到法语时会去吮吸奶嘴
Now, it's interesting because the other four books of the Pentateuch never mention a king. In Genesis through Numbers none of the legal materials say when you have a king this is what he shall do.
有趣的是,摩西五经中的其他四本经书,从来没有提到过国王,从《创世纪》到《民数记》,从没有一份正规的材料说,当你有了一位国王后,这些就是他应该做的事情。
So tell me about. You have done music, where do these things intersect for you?
那么,你已经做过音乐和,艺术,这些事情的交叉点在哪里呢?
and if you've never been, don't do this, it's largely because there are these very sensitive moving parts and there are relatively few moving parts left in today's computers.
如果你没做过,不要做这些事情,主要是因为电脑里面有一些很敏感,且高速运转的部件,以及相对不运转的部件。
OK. Second thing I need to do, though, is I need to, when I get those values, I want to hang on to them.
好,我需要做的第二件事情,就是我需要去,当我得到这些值后,我想抓住这些值。
Another thing that these kings are seen to do, which is in a way even at a lower level, is to be herdsmen.
这些国王们平时还,做一些更加低等的事情,比如放牧
Indeed, no computer actually does this.
实际上,没有电脑真正会做这些事情
But as you get older and you have a lot of spare time, you think about what you are doing, which is something I have the luxury of doing right now, and I realized this is more tricky.
但随着你们年龄的增长,有更多空闲时间之后,你就会思考你做的事情,我现在就有很多闲暇思考这些问题,我意识到这东西其实很精妙
Like if you're one of the people who hasn't been writing down things as you go along, and then you enter things at the end of the day, and I suspect that's the majority of you, you may have entered things into your record and then later gone and said, oh I forgot, I had this thing!
比如你是这些人之一,没有及时记下自己做的事情,在一天结束时你要提交信息了,我猜你们中的大部分,输入自己的信息,之后可能会发现,我忘了,还有这个
when you've never done something before.
当你从来没有做过这些事情之前。
And maybe it does it kind of the same way that I do it but my computer doesn't have feelings in the same sense.
也许它做这些事情的方式和我是一样的,但我的电脑却并不能,像我一样,拥有情感
But things like that... They are great opportunities.
我做的就是类似的事情。,这些都是难得的机遇。
I'm going to do something which somehow we are told never, ever to do, which is to just cancel the dts.
我接下来要做一件以前绝对不允许的事情,约去这些dt
OK, in each case, what these things are doing, is they're doing, what sometimes gets referred to as operator overloading.
这将会是个默认的或者说是,通用的来比较对象是否相同的方法,好,在每个例子中,这些事情正在做的,就是,一些与操作符重载有关的东西。
He has to modify his plans for the first couple, by barring access to the tree of life. That was not something presumably he planned to do This is in response to, perhaps, their unforeseen disobedience certainly the way the story unfolds that's how it seems to us.
他更改了他的原计划,除了不能接近生命树,这些并不是他本打算做的事情,这也许是对意外挑衅的回应,故事是对后人的警告。
So it does that for us so that you can get away with just knowing the address of the first byte and it will make sure that you know when to stop by including the special value so, in fact, get the string if you type in a three-letter word, we allocate four bytes no matter what because we need an additional byte 0 for this special sentinel value back slash zero at the very end.
它为我们做了这些事情,这样我们就可以,通过第一个字节的地址,它还可以通过包含一个特殊的值,来保证在哪里停止,如果你输入了一个三个字母的单词,就可以获得那个字符串,不管怎样,我们分配四个字节,因为我们在末端需要一个额外的字节,来保存这个特殊的标志值--反斜杠。
I stress it in particular because I know you're all going to get into this stage; you've got a problem set due in a couple of hours, you're still writing the code, you don't want to waste time, and I'm going to use quotes on "waste time", doing those extra things to do the defensive programming, you just want to get the darn thing done.
我特别强调了这一点,因为我知道你们都会慢慢成为程序员;,你在写代码过程中造成了一系列的错误,你还在写代码,你不想浪费时间,我想把“浪费时间“用引号圈起来,浪费时间来做因为防卫性程序设计,而带来的这些额外的事情,你只想赶紧把程序写完,这不是一个好习惯,因为当你做完回头。
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中找到它的地址,然后做我想做的事情,返回我处理后的东西,我可能改变了这些源变量。
One of the things you should begin to do, is to recognize what identifies those classes of algorithms, so you can map your problems into those ranges.
你们现在开始要做的事情之一,就是要学会辨别这些算法,这样你就能为你的问题,选择对应种类的算法了。
There are different activities you can do where if you're good enough at them, if you're expert enough at them, you don't know you're doing them.
有很多不同的事情,如果你很擅长这些活动,你对这些活动非常在行,那么你是不会意识到你正在做这些事情的。
应用推荐