![]() |
|
How can a computer, which is capable of executing only programs written in binary machine language, run a program in a "high-level" language, such as JavaScript? The following lab exercises will demonstrate for you how a translator can convert code written by human programmers into machine executable commands. | |
|
| ||||
|
| ||||
| Module Quiz |
| |
The text portion of this module addresses the question of how a computer which understands binary machine language can execute the kind of instructions we write in high-level programming languages, like JavaScript, detailed in Module 5. The answer, of course, is that it turns programs on themselves, to serve as translators. The structure and typical content of these different languages, as well as the techniques employed by the translator programs, are the focus of this module. | |
Like modern translator programs, the Rosetta Stone accomplished its translation in stages (converting hieroglyphics, first into demotic, and then into Greek). Replace hieroglyphic with high-level programming language, demotic with assembly language, and Greek with machine language, and you've got a reasonable model for how modern computers implement modern programming languages. Thus, the Rosetta Stone serves as an effective metaphor for this module. |