andrew@orca.UUCP (Andrew Klossner) (08/15/83)
A correspondent questions whether Basic and Cobol can be classified as "high level" languages while C is regarded as a "medium level" language. The "level" designation has come to have two meanings. One is the relative power of the average statement in the language, which translates directly into how much runtime support is required. The other is the distance between the computation model used by the language and the actual underlying computer. In both cases, assembly language is at the "lowest level". Using both of these meanings, Basic and Cobol are at a higher "level" than C. The Basic programmer can do some very expensive operations with a few keystrokes, for example with statements such as "MAT A=INV(B)" (matrix inversion and assignment). By contrast, C requires explicit procedure calls to do anything more complicated than a structure copy. The computational model of C is much closer to the "real" model than are those of Basic and Cobol. For example, C supports pointers; Basic/Cobol programmers must get by with array subscripting. C "knows" that memory is made up of bytes whose size is (almost always) eight bits (any pointer can be cast to (char *)). As a result, machines which don't fit this model, such as the PDP-10, are much more reluctant targets for C compilers than for Basic and Cobol. None of this should be construed to imply that I would rather program in Basic or Cobol than in C. On the other hand, if I had access to a compiler for a *real* high-level language, like Algol-68 ... -- Andrew Klossner (decvax!teklabs!tekecs!andrew) [UUCP] (andrew.tektronix@rand-relay) [ARPA]