• I'd really like to have that modularity that says, I'm only going to get access to the values, not by calling their names, but by calling some specific method to get access to their names.

    这样我们就丢掉了代码的模块化,我很希望代码有这样的模块化:,我访问变量的值,不是通过直接调用它们的名字,而是通过调用某个可以,访问这些变量名的方法来访问。

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

  • If somewhere later on in the code it shifts to string, I might not be manipulating that and getting actual values out, but not what I wanted, and it's going to be really hard for me to chase it back.

    然后后面的一些代码,把变量类型变为了字符串,我可能不会通过实际操作,去取得实际的变量的类型,但是这并不是我想要的类型,而且对我来说把类型,变回去也很困难。

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

  • If you're not updating some variable by incrementing it or decrementing it -- if you're not changing anything, presumably the conditions are never going to evaluate to false or the opposite, so you're just going to have an infinite loop, which might be your goal, but odds are it's not.

    如果你不通过增加或减少它来改变一些变量,-如果你不改变什么,大概那个条件永远不会变成错误的,或相反的,所以你将得到一个无限循环,那可能是你的目标,但可能也不是。

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

  • I want-- I know I'm running you slightly over, I want to do one last example, it's, I also want to be able to do, have variables to store things.

    我想-我知道讲的有点多了,我想给大家看最后一个例子,这里我想做的是,通过变量来存储东西。

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

  • Well, things can be fixed by a little trick called global variables.

    好的,问题可以通过,一个叫做全局变量的东西来解决。

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

  • I think of data hiding as basically saying, one can only access instance values, or, we'll call them that, instance values through defined methods.

    一个人仅仅可以访问实例变量,或者,我们可以这么来说,通过定义好的方法,来访问实例的变量

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

  • I would only ever access the values through a method.

    如果我真的很讲卫生,我只会通过一个方法来访问变量值。

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

  • Well, you can use what's called an array which is kind of a list or a little satchel of that you might physically carry that you can put things in again and again, and with an array can you actually keep track of not just numbers but any kinds of things, other sprites or other pictures, or perhaps a little something like this.

    你可以使用数组,它其实是个列表,或者说是个小包,你可以把东西一个个放到里面,通过数组你可以保存任何种类的变量,图片或者像,这个例子中的一些小变量,而不仅仅是数字。

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

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

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

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