But we know already from week zero that computers ultimately represent all information with numbers, and if they want to represent letters inside memory, well what do they do or what do they use?
但是自从上周我们已经知道,计算机最终是用数字来表示所有的,信息,如果它们要描绘,在内存中的字母,它们该怎么做,用什么方式呢?
But at the end of the day, and here's why we just went with binary and not decimal years ago, when you have one implement a computer with a physical device, it's actually really easy to represent the notion of on or off.
但是最终,之前我们采用二进制,而不是十进制,主要是因为当我们用一台实体机器运行计算机时,这实际上很容易用开或者关的概念来表示。
But one of the teaching fellas also passed long to us recently, a little real world example of what happens when you're not mindful of various data types and you're not mindful of the imprecision that's inherent in representing data in a computer, at least using a language like C and low level primitives like floats and even doubles.
最近有个助教告诉我们,一个现实世界中的例子,当你不注意各种各样的数据类型,也不注意在计算机中表示数据时,其内在的不精确性,至少在用像C语言,和float甚至double型数据时,那将会发生什么?
And, again, the rectangle represents your computer's RAM, the bottom represents the part of RAM that we generally call the stack, main conceptually ends up on the bottom of the stack followed foo by its local variables then the function say foo that it calls and on and on and on and up, but there is, in fact, something above all of this and we've seen this picture briefly and that's this thing called the heap.
再次,矩形表示的是计算机内存,底端表示内存的一部分,通常我们把它叫做堆栈,main函数在,堆栈的底端,之后是,它的局部变量,然后是它调用的函数,等等等等,但是那里有,实际上,在这个上面,我们粗略看看这个图画,这个东西叫做堆。
应用推荐