Nand2Tetris Unit 0 Introduction

来自iCenter Wiki
2016年2月3日 (三) 10:39Echothu讨论的版本

跳转至: 导航搜索

Introduction

S:Hello, and welcome to Nand to Tetris.My name is Shimon Schocken, and I'm a Professor of Computer Science at IDC Herzliya and Visiting Professor at the Hebrew University of Jerusalem.

N:Hi, I'm Noam Nisan, a Professor of Computer Science at the Hebrew University of Jerusalem, and a researcher at Microsoft. Together we'll teach you this course.

S:And and the first thing that we're going to want to do in this unit is to give you the overall picture of what this course is all about. Well, in this course we're going to build a complete general purpose working computer from the ground up. Hardware and software. And, we're going to divide this huge enterprise into two separate courses. In the first course, which is going to be seven weeks long, this course we're going to build the hardware of the computer. And in the second course that will be offered, later, we're going to do complete the picture and build the software hierarchy that sits on top of the computer that you will build in the first course. So that's what we're going to do in the next seven weeks. We're going to focus on building the hardware of the computer, which we call heck. So it's going to be a great journey consisting of seven weeks, six projects, one computer and zero prerequisite knowledge. We assume no knowledge whatsoever in computer science or engineering. Everything will be given to you in the course itself. So this has been our first unit in Nand to Tetris and coming up is the road ahead in more detailed description what we're going to do in this course.

文件:Nand to Tetris- the big picture.png

The Road Ahead

We're going to start this course by describing the main mental tool that computer science uses all the time that we're going to use in this course and in fact the main mental tool that will allow us to design a extremely complicated artifact step by step. Many of you have probablytaken a programming course. Many of you may have not, but mainly you have. Usually, in such a course, the fir, in the first class, in the first lesson, you start looking at the very, very simple program, sometimes called Hello World. And this is a program that just prints Hello World on the screen. Usually, you start discussing the various fluff. Eh, around the commands, basically stating, oh, here is the program, and this is how it's supposed to be written. You talk about various commands, eh, in the program. For example, the 4th line, or the 5th line, the, in what you see in front of you basically tells the computer to print a string "Hello World!" on the screen, and that's really what the program does. And you discuss all that things. And that's how you start a programming course, a programming 101 course. Now when you think about that that's very problematic. There are a lot of things that are under the hood here. First of all there's this amazing thing. What you see is the program with just a bunch of letters. So for example if you have the p letter, this is a letter p. It's not doing, doing anything, it's just a letter. And in fact we know that in computers the letter p is represented by a number. So we have the number 112, and then you have a number 114 for r, and so on. And somehow these letters are supposed to do something, how does, does that happen? Well, you are told something about compiler that translated to a different language. And the other language, a computer hardware can execute, but how does that even work? All that is swept under the rug when you start introduction to computer science or to programming. Similarly, if you look at even the simplest programs, the simplest command, for example, print "Hello World". How are you supposed to do that? Printing Hello World on the screen actually involves setting a bunch of pixels on your screen to be more lighter or darker. And it's a lot of pixels and you have to actually the pixels that are lighter in a very special order to somehow represent the letter H and then the letter E. How is that all, all, all that happened that's an extremely complicated thing and yet you just use it. And that is also swept under the rug. Again you're told about standard libraries and operating systems that do all that for you. But, you don't really worry about them. Why I don't we have to worry about them? The main secret of computer science is the fact that you really don't have to worry about them. You can really start and do programming 101, as many students have done throughout the years, without worrying about all these very basic questions. How do that happen? How come you don't need to worry about how? Because, it's enough to worry about the what. It's enough to use, what the programming language is supposed to do. And you don't need to worry about what happens behind it. Because you're only using it. You're not now actually trying to duplicate it. The how of something is called implementation. How do you actually make it happen. That's called to implement it. The what. It's called the abstraction. That is if you sell the computer languages of both to do such and such, you don't need to worry about how it is done. But the such and such, the exact specification of the such and such, that's the abstraction that we have that's the interface that you get to work with, and you only need to worry about that when you actually program. When you are taught, In programming 101, that you actually can run that program. The whole point is that you only need to worry about the abstraction.

From Nand to Hack

From Hack to Tetris

Project 0 Overview