Prev | Current Page 124 | Next

Carl Reynolds and Paul Tymann

"Schaum's Outline of Principles of Computer Science"


COMPILERS AND INTERPRETERS
With the development of FORTRAN came a new and more complex program for creating machine language
from a higher-level expression of a programmer??™s intent. The new program was called a compiler, and the job
of a compiler is to translate a high-level programming language into machine code.
The input to a compiler is the source code written by the programmer in the high-level language. We will
show a simple example program from a seminal book in statistics entitled Multivariate Data Analysis, written
by William Cooley and Paul Lohnes in 1971. The book was remarkable in its time for its inclusion of many
FORTRAN programs in source code form.
In 1971 the input would have been from punched cards, and the output would have been to a printer. In the
read statements below we have replaced the card reader device ID of 7 with the asterisk character to allow the
program to read from the keyboard of the PC. Likewise, in the write statements, we have replaced the printer
device ID of 6 with an asterisk. This permits the output to go to the computer display.
FORTRAN of that time was a column-oriented language (newer FORTRAN standards have allowed ???free
format??? statements). Statement numbers appeared in columns 1??“5, and statements were written in columns
7??“72.


Pages:
112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136
Władysławowo wakacje alveo nasze hotele aurora amefa baterie łazienkowe