Short Code was one of the first attempts to let a programmer write mathematical expressions instead of raw machine instructions. John Mauchly proposed it in 1949 under the name Brief Code, and it later became the Short Code language for the UNIVAC I, the first commercial computer produced in the United States. Programs written in it ran far slower than hand-coded machine instructions, but they were much faster to write and check, a trade-off that would define high-level programming for decades.

Origins at Eckert–Mauchly

John Mauchly and J. Presper Eckert had built ENIAC at the University of Pennsylvania and then founded their own company to build commercial machines. Its first delivered computer was the BINAC, completed in 1949 for Northrop Aircraft. Mauchly's proposal for Brief Code came from the same environment: engineers and mathematicians who knew how tedious it was to translate a formula into a long list of numeric instructions.

William F. Schmitt implemented a version for the BINAC in 1949. He then produced a new version for the UNIVAC I around 1950, by which time the system was known as Short Code (sometimes Short Order Code). The UNIVAC I itself was first delivered to the U.S. Census Bureau in 1951, and Short Code was available to its early users. The company had been taken over by Remington Rand in 1950, so later documentation appears under that name.

How the Short Code language for the UNIVAC I worked

Short Code was an interpreter, not a compiler. The program stayed in memory in its coded form, and a resident routine read each code at run time and carried out the matching machine operations. The key ideas were simple:

  • Variables and constants were assigned to memory locations and referred to by short two-character names.
  • Operations such as equals, addition, division, parentheses, powers, roots and absolute value were represented by two-digit numeric codes.
  • Codes were packed into machine words. The UNIVAC I used 12-character words, so a single word could hold several two-character elements of an expression.
  • Expressions kept their mathematical order, so a programmer could transcribe an equation largely as written rather than reorganising it around the machine's accumulator.

The price was speed. Short Code programs are commonly described as running roughly fifty times slower than equivalent machine code, because every operation passed through the interpreter.

Illustrative example

The example below is illustrative. It follows the code table as usually reproduced in histories of the language, but it should not be read as a verified listing from original UNIVAC documentation. Suppose a programmer wants to compute an equation of the form X3 = (X1 + Y1) / X1 * Y1:

Equation:     X3  =  (  X1  +  Y1  )  /  X1  *  Y1
Short Code:   X3  03 09 X1  07 Y1  02 04 X1     Y1

Codes used (illustrative):
  03  =      09  (      07  +
  02  )      04  /      multiplication by placing operands side by side

The programmer still had to assign memory to each variable and lay the codes out in words, but the structure of the formula survived the translation. That was the real novelty.

How Short Code was used

Short Code was aimed at scientific and engineering calculations, the kind of work where formulas dominate and where getting a correct answer mattered more than squeezing out every bit of speed. It did not offer the data handling, input and output facilities or the error checking later expected of a programming language, and because of its performance cost, production code that ran often was still written by hand in machine instructions.

Its practical reach was limited by the small number of machines it ran on. BINAC was a one-off delivery, and the UNIVAC I was built in small numbers, so Short Code's direct user base was always small.

Influence and legacy

Short Code's main contribution was proof of concept. It showed that a machine could take something resembling mathematical notation and carry it out automatically. Grace Hopper, who joined Eckert–Mauchly in 1949, worked in the same company when she produced the A-0 system in 1952 and later the English-like FLOW-MATIC. Historians are cautious about drawing a direct line from Short Code to those systems, but they grew in the same place and addressed the same problem.

The interpreter-versus-compiler tension it exposed also became a recurring theme. Short Code paid for convenience with run-time interpretation. Later systems such as Autocode and Fortran tried to keep the convenience while translating the program once, ahead of time, into efficient machine code.

Is Short Code still used?

No. Short Code disappeared along with the machines it ran on, and no modern implementation is in practical use. It survives in histories of computing as one of the earliest high-level languages to actually run.

The Short Code language for the UNIVAC I was slow, narrow and tied to a handful of machines, but it established a principle that every modern language depends on: people should write what they mean, and the computer should handle the translation.

Frequently asked questions

Who created Short Code for the UNIVAC?

John Mauchly proposed the language in 1949 as Brief Code. William F. Schmitt implemented it, first for the BINAC in 1949 and then for the UNIVAC I around 1950, when it took the name Short Code.

Was Short Code a compiled or interpreted language?

It was interpreted. A routine in memory read each coded operation at run time and executed the corresponding machine instructions, which is why Short Code programs were commonly cited as about fifty times slower than hand-written machine code.

Is Short Code considered the first high-level programming language?

It is often described as one of the first high-level languages to run on an electronic computer. Konrad Zuse's Plankalkül was designed earlier but was not implemented at the time, so the answer depends on whether you count designs or working systems.