Introduction to COBOL
COBOL (COmmon Business-Oriented Language) is a compiled, imperative, English-like programming language designed for business data processing: reading and writing large volumes of records, exact decimal arithmetic on money, and producing reports.
1.1 What is COBOL?
COBOL (COmmon Business-Oriented Language) is a compiled, imperative, English-like programming language designed for business data processing: reading and writing large volumes of records, exact decimal arithmetic on money, and producing reports. A COBOL statement reads almost like a sentence:
ADD SALES-AMOUNT TO REGION-TOTAL.
IF REGION-TOTAL > SALES-TARGET
DISPLAY "Target reached"
END-IF.1.2 Key characteristics
Verbose, self-documenting syntax — programs are meant to be readable by auditors and business analysts.
Fixed-point decimal arithmetic built in — PIC S9(7)V99 holds money exactly, with no binary floating-point rounding surprises.
Record-oriented data descriptions — the DATA DIVISION describes the exact byte layout of records, files, and screens.
Strong file handling — sequential, relative, and indexed files are part of the language, as are SORT and MERGE.
Static memory model — classic COBOL allocates all storage at load time (no heap needed), which is fast and predictable.
Extreme backward compatibility — code written in the 1970s often still compiles today.
1.3 History
Grace Hopper's FLOW-MATIC (UNIVAC) proves that English-like business languages work; IBM's COMTRAN is another influence
CODASYL (Conference on Data Systems Languages) meets at the Pentagon (May 1959), sponsored by the US Department of Defense; the Short-Range Committee designs COBOL. Hopper is a technical adviser
COBOL-60 specification published; the same program runs on RCA and UNIVAC computers in December 1960 — an early demonstration of portability
COBOL-61, COBOL-61 Extended, COBOL-65 refine the language ANSI COBOL-68 — first American National Standard
COBOL-74 — file organization improvements, DELETE for relative/indexed files, inter-program communication
COBOL-85 — structured programming: scope terminators (END-IF, END-PERFORM), EVALUATE, inline PERFORM, nested programs, INITIALIZE, reference modification
Intrinsic functions amendment (FUNCTION CURRENT-DATE, NUMVAL, UPPER-CASE, …)
ISO/IEC 1989:2002 — object orientation (classes, methods, INVOKE), free-format source, *> inline comments, LOCAL-STORAGE, recursion, pointers, user-defined functions, national (Unicode) data, boolean data, EXIT PERFORM
ISO/IEC 1989:2014 — IEEE 754 floating point (FLOAT-BINARY, FLOAT-DECIMAL), dynamic-capacity tables, method overloading, new rounding modes, several features made optional or removed
ISO/IEC 1989:2023 — standardized LINE SEQUENTIAL files, transaction verbs (COMMIT, ROLLBACK), bit-manipulation operators, asynchronous messaging (SEND/RECEIVE), more intrinsic functions, cleanup of obsolete features
In practice, vendors implement the standards selectively. IBM Enterprise COBOL follows COBOL-85 plus many 2002/2014 features and its own extensions (JSON, XML, UTF-8). GnuCOBOL implements most of COBOL-85 and large parts of 2002/2014/2023 and emulates IBM and Micro Focus dialects.
1.4 Why learn COBOL now?
Industry surveys commonly estimate hundreds of billions of lines of COBOL in production, processing a large share of the world's card payments, bank ledgers, insurance policies, and government benefits. The experienced workforce is retiring, modernization projects need people who understand both COBOL and modern stacks (APIs, Java, cloud, DevOps), and COBOL teaches discipline about data layout, exact arithmetic, and batch processing that transfers to any data-heavy domain.