# FLOW-MATIC

FLOW-MATIC, originally known as B-0 (Business Language version 0), was the first English-like data processing language. It was developed for the UNIVAC I at Remington Rand under Grace Hopper from 1955 to 1959, and helped shape the development of COBOL.

## Development

Hopper had found that business data processing customers were uncomfortable with mathematical notation:
   I used to be a mathematics professor. At that time I found there were a certain number of students who could not learn mathematics. I then was charged with the job of making it easy for businessmen to use our computers. I found it was not a question of whether they could learn mathematics or not, but whether they would. […] They said, 'Throw those symbols out—I do not know what they mean, I have not time to learn symbols.' I suggest a reply to those who would like data processing people to use mathematical symbols that they make the first attempt to teach those symbols to vice-presidents or a colonel or admiral. I assure you that I tried it.
In late 1953, she proposed that data processing problems should be expressed using English keywords, but Rand management considered the idea unfeasible. In early 1955, she and her team wrote a specification for such a programming language and implemented a prototype. The FLOW-MATIC compiler became publicly available in early 1958 and was substantially complete in 1959.

## Innovations and influence

The Laning and Zierler system was the first programming language to parse algebraic formulae. When Hopper became aware of that language in 1954, it altered the trajectory of her work. FLOW-MATIC was the first programming language to express operations using English-like statements. It was also the first system to distinctly separate the description of data from the operations on it. Its data definition language, unlike its executable statements, was not English-like; rather, data structures were defined by filling in pre-printed forms.
FLOW-MATIC and its direct descendant AIMACO shaped COBOL, which incorporated several of its elements:
* Defining Input & Output Files and printed output in advance, separated into INPUT files, OUTPUT files and (HSP) High Speed Printer outputs. INPUT <FILE-NAME> <FILE-LETTER>; OUTPUT <FILE-NAME> <FILE-LETTER>; HSP <FILE-LETTER> .
* Qualification of data-names (IN or OF clause).
* IF END OF DATA (AT END) clause on file READ operations.
* Figurative constant ZERO (originally ZZZ...ZZZ, where number of Zs indicated precision).
* Dividing the program into sections, separating different parts of the program. Flow-Matic sections included Computer (Environment Division), Directory (Data Division), and Compiler (Procedure Division).

## Sample program

A sample FLOW-MATIC program:
Sample Notes
* Note that this sample includes only the executable statements of the program, the COMPILER section. The record fields PRODUCT-NO and UNIT-PRICE would have been defined in the DIRECTORY section, which (as previously noted) did not use English-like syntax.
* Files are referred to by the letter at the end of the FILE-LETTER. Example: FILE-A is referred to later just by A and is for ease of reference in following code.
* Operations are numbered in an unbroken sequence from 0..n and are performed in that order unless a statement to the contrary is reached/made (executed) (JUMP, etc.).
* The highest numbered operation is the one that stops the program.
* A much more detailed overview of FLOW-MATIC is available in the manual titled, FLOW-MATIC PROGRAMMING SYSTEM