• Or take this value out of memory, run it through some other simple operation, stick it back in memory.

    或者从记忆存储器取出一个结果,在类似的操作中运行,再插回到存储器

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • Yeah, it's kind of simple, but it gives me an ordered list of these things, And let's run it. OK.

    让我们来运行运行吧,好,我会先去搜索一些数组没有的元素,让我来试试,看-1在不在这个数组里。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • All right so it has to live in RAM as opposed to the hard drive because otherwise things would be terribly slow as you know so it's much better if your programs live while they're running in RAM and they end up in what's called the tech segment.

    好的,它存在内存,而不是硬盘,因为,否则程序会非常的缓慢,程序在内存中运行会好得多,它们在技术段,的地方结束。

    哈佛公开课 - 计算机科学课程节选

  • It's the various programs you run on your computer along with the various data files that you have saved on your hard drive,and so forth.

    是你自身这个电脑中运行的各种程序,硬盘存有的各种数据和文件,类似种种。

    耶鲁公开课 - 死亡课程节选

  • To do well in investing you have to have your own independent view of things and really be thinking about how things work and he is someone who does that.

    如果你想要在投资领域表现出色,你就必须有独立的观点,了解事物的运行规律,而他正是这样一个人

    耶鲁公开课 - 金融市场课程节选

  • If you live in a society that operates under those rules, then it should be up to the government to decide how those resources that come back through taxation are distributed because it is through the consent of the government.

    如果你在一个按照上述规则运行的社会生活,那么就应该由政府来决定,如何分配,通过征税收回的资源,因为那是政府一致表决通过的。

    耶鲁公开课 - 公正课程节选

  • Notice one last piece. If I'm going to do that, run through all possible answers, I still want to know, gee, what if there aren't any answers? How do I return that case?

    注意最后一段,如果我要这样做,也就是运行所有可能的答案,我还是想知道要是没有结果呢?,在这个例子应该返回什么呢?

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • And those instructions, by the way, are very simple: they're things like, take the value out of two places in memory, and run them through the multiplier in here, a little piece of circuitry, and stick them back into someplace in memory.

    顺便说一句,那些指令非常简单:,他们从记忆存储器,取出两个位置的结果,在倍增器中运行,一小部分电路,再将它们插回存储器的某些地方去。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • So if you're coming from prior background, your code might work a little differently on a different system if you don't use those flags.

    如果你来自一个先前的背景,如果你们没有使用这个版本标志的话,在一个不同的系统,你的代码可能运行地不太一样。

    哈佛公开课 - 计算机科学课程节选

  • It's a bad habit to get into, because when you come back to it, it may haunt you later on down the road. So really get into that notion of trying to be defensive as you program.

    运行程序的时候,错误就会出现缠住你了,因此现在我们真的要培养,在程序有防卫性设计的概念。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • And this was just a formal way of describing the best case running time and in the case of Selection Sort, what was the best case running time?

    这是描述最好情况下运行时间的,一种正式的方式,在选择排序,最理想的运行时间是多少呢?

    哈佛公开课 - 计算机科学课程节选

  • One of the inputs to the problems we're gonna be working on this semester and if you continue on in this world how much thought it takes to implement something, how much time it takes to run something, how much space it takes to run something?

    我们将在本学期集探讨这些问题,或者在课程之后你们也可以继续研究,为实现一些功能要有多少想法,在运行过程又将花费多长时间,需要多大的空间?

    哈佛公开课 - 计算机科学课程节选

  • nano Well, anytime you run a program at the command line, like nano, you've almost always been putting one or more words nano hello c GCC hello c after that program's name; nano hello dot C, GCC hello dot C, and any number of MKDIR for make directory, and then peace at one or similar.

    好的,任何时候在命令行中运行一个程序,就像,你几乎总是用1个或多个单词,在程序名的后面,许多的建立一个新的子目录,然后恢复平静。

    哈佛公开课 - 计算机科学课程节选

  • I should really just put it in a nice test harness, where I run 100, 200, 1,000 trials, but I didn't want to bore you with that here.

    我应该把它放到一个测试组件,我运行100次,200次,1000次,但是我现在不想用这个来烦你们。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • Right. Those things are going to stack up, and eventually it's going to run out of space.

    不用占用其他空间的算法,对,这些东西在运行的过程会累积起来。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • A huge one is, are you actually running the code you're looking at in your editor.

    一个很大的错误就是你运行的程序,是否是你在编辑器看到的程序。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • So in this case, it just keeps chopping down from the back end, which kind of makes sense, all right? But in a fixed number, in fact, twenty-three calls, it gets down to the point of being able to say whether it's there.

    所以在这个例子,我们能理解他从后端开始排除元素,这,里事实上每次会确定的运行23次,找到最终的元素,我们来换个方向,对。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • And that's basically the process of ascertaining why the program is not working.

    这其实是一个查明为什么程序,不运行或者不按期待中运行的过程。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • Well, what I always do in anything like this is, the first thing I do is, I run it on something where I can actually compute the answer in my head. So I get a sense of whether or not I'm doing the right thing.

    好的,我常常在,这种问题会做的是,我会做的第一件事是我,会先带入我可以心算的值来运行,因此我能够知道我是否做对了。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • But that little short hand there is doing exactly the same thing. It is adding that value into some digits and putting it back or signing it back into some digits. And I'll walk through that loop and when I'm done I can print out the total thing does. And if I do that, I get out what I would expect.

    加上得到的这个数的,但是这个缩写声明其实是进行了同样的操作,它把我们得到的这个数加到一个数上面去,然后用和对这个数进行了重新赋值,在循环会去遍历字符串,当完成循环后,程序会显示数字的总和,如果我运行,这个程序的话,我会得到我期待的结果。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • skittles So when you compile a program called A dot out, or skittles or wherever, and you double-click that program, or our in our command line environment, run it with dot slash skittles, that program is loaded Microsoft Word into memory just like Microsoft Word or whatever would be on your own computer.

    当你编译一个程序a,out,或者,或其他的,你双击那个程序,或着在我们的命令环境,采用,/skittles来运行它,那个程序被加载到,内存,就像,或者你电脑上的其他程序。

    哈佛公开课 - 计算机科学课程节选

  • OK. Having done this now, I can simply go ahead and run this, and in fact if I go up here to run, you'll see I've got both an option to check the module, though in this case I'm just going to run it.

    好,讲完了这些,我可以去执行程序了,实际上如果我在这里运行,你们会看到我同样得到了,一个可以同时检查模块的选项,虽然在这个例子我就是直接去运行程序了。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • Does it give you the answer that you expected it to give? Often, in practical problems, you'll spend just as much time doing performance debugging. Why is it slow?

    它返回了期待的结果了么?通常,在实际的问题你会花,同样多的时间在性能调试上,它为什么运行这么慢?

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • Suppose instead, I want a machine that can take a recipe, the description of a sequence of steps, take that as its input, and then that machine will now act like what is described in that recipe.

    假设换成这个,我想要一台可以安装描述,一系列步骤的结果的方法的机器,把那个当做输入设备,然后那台机器可以像方法,描述的那样运行了。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • And I've put it in my debugging code.

    调试的代码去,然后运行看看结果。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • Remember last time, I said that there's different kinds of complexity in our code, and I suggested for simple branching programs, the amount of time it takes to run that program is, in essence, bounded by the number of instructions, because you only execute each instruction at most once.

    但是这里有个很重要的点,记得上节课,我提过在我们的代码,有不同种类的复杂度,而且我还说了对于简单的分支程序,运行这种程序需要的总体时间,大体上,是和指令的数目相关的,因为每个指令只会被执行最多一次。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • So what's going to happen here? If I'm inside this FOR, OK, and I'm running around, if I ever hit a place where this test is true, I'm going to execute that return, return that return returns from the entire procedure. OK? So the return comes back from the procedure.

    那么这里发生了什么呢?,如果我是在这个for循环里面,我正在运行,如果我运行到test的值为真的地方,我就会执行,这个return将会返回整个程序的值,明白了吗?所以它将会从整个程序返回值。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • So the question was, why is this return down at this level, it says, well if I ever execute out of this FOR loop, I get to the end of the FOR loop without hitting that branch that took me through the return, then and only then do I want to actually say, gee, I got to this place, there isn't any value to return, none I'm going to return none and none.

    问题是,为什么它是在这个级别上返回值呢,意思就是如果我出了这个for循环,就意味着我运行的过程没有走到任何,带return的支路上去,这时也只有这时我才能说天呐,我终于走到这儿了,这时不会返回任何值,只会返回none和。

    麻省理工公开课 - 计算机科学及编程导论课程节选

  • I have connected to the course's central server from my own laptop and via dot slash chart am I about to run a little program that depicts as best we can with what with generally call ASCII art -- -- it's really all you can do in a terminal window like this -- our numbers from the past few years.

    我已经通过我的电脑连接到了课程的心服务器,在我的笔记本电脑上,通过键入“,/chart“,我将要运行一个被描写成,“ASCII码艺术“的小程序-,在一个这样的终端窗口你们都可以做到-,过去几年我们的人数。

    哈佛公开课 - 计算机科学课程节选

  • I mean what if you're running so many things, what if the user has copied and pasted their thesis and just pasted it at the blinking prompt such that you're now out of memory because your computer is somewhat limited in memory so get string cannot possibly return all those characters or fit all of those characters in memory and return to you the address of the first.

    如果你运行了很多程序,假使用户复制粘贴了他们的论文,只是粘贴在光标提示符那里,这样就出现了内存不足,因为你们的计算机的内存是有限的,所以GetString不可能返回所有的字符,或者保存这些字符到内存,并且返回第一个字符的地址。

    哈佛公开课 - 计算机科学课程节选

$firstVoiceSent
- 来自原声例句
小调查
请问您想要如何调整此模块?

感谢您的反馈,我们会尽快进行适当修改!
进来说说原因吧 确定
小调查
请问您想要如何调整此模块?

感谢您的反馈,我们会尽快进行适当修改!
进来说说原因吧 确定