• If we weren't so pressed for time, I kinda wanna see how long we could get away with this before it gets awkward, but that, in fact, is an infinite loop t hat's hopefully deliberate.

    如果有时间,我想看看,我们需要花多长时间解决这一问题,事实上,它是我故意,使用的无穷循环。

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

  • The cookies were going back and forth and back and forth and the hearts up and down, well, this thing that we had that called a loop last week with a forever block with a statement inside of it is simply gonna look a little something like this.

    这些饼干人来来回回的移动,还有这些爱心们上上下下地漂浮,都用到我们上周提到过的循环结构,当然还有个声明在里面,就有点像屏幕上,显示的这样。

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

  • You could run through a little loop to say keep trying until you get one. But one of the ways I could deal with it is what's shown here.

    你可以运行一个小循环来不断地做,直到得到一个输入,但你应该做的是弄明白这里到底要干什么。

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

  • If I want a copy of the string, I've got to whip out my week 1 skills of just iterating with a four loop from left to right and make copies of those characters.

    我需要那个字符串的一个拷贝,我使用,第一周的技巧,从左到右做四次迭代,然后复制这4个字符。

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

  • So what I wanted to do is loop back, at least with a couple of things that we see recurring and very understandably so, but let's try to clear up a couple of frequently occurring issues.

    所以我想要做的是回环,至少用两三个,我们看到的东西返回,并且可以理解地,让我们试着处理几个,频繁发生的事情。

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

  • So with this type of loop, things get a little bit reversed.

    这种类型的循环,东西变得有点颠倒的。

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

  • We start with j pointing here, and we can see what this loop's going to do, right? j is just going to move up.

    我们让j指向这里,我们能看到这个,循环要做什么?,对吧,j要开始移动了。

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

  • How do I know when I'm done with the loop?

    我怎么知道循环完毕了呢?

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

  • The difference with the do while loop, as the syntax kind of suggests, is that this construct is going to do something no matter what.

    作为建议的语法,do,while循环的不同之处,是这个结构不管怎么样,它会做一些事情。

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

  • I'm again, iterating with this four loop, same code as before.

    我再次,重复使用for循环,同样的代码。

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

  • So in other words, if you terminate these lines early, if you terminate the four loop early, if you terminate an if condition early with that semicolon, the code may very well work; and this is a common source -- of frustration and conundrum because you don't -- because your code looks right and yet it's misbehaving, but that semicolon means stop looking for subsequent lines of related code.

    换句话说,如果你用分号过早的终止了这些代码行,如果你过早地终止了那个for循环,如果如此,一个if条件,代码可能可以运行,这就是,挫折和问题产生的源头,因为你没有-,因为你的代码看起来是正确的,但是运行是错误的,那个分号的意思是,停止寻找后面相关的代码。

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

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

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

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