The COBOL Programming Language
resources updated everyday:
COBOL (Common Business Oriented Language) was one of the earliest high-level programming languages. It was developed in 1959 by a group of computer professionals called the Conference on Data Systems Languages (CODASYL).
Since 1959 it has undergone several modifications and improvements. In an attempt to overcome the problem of incompatibility between different versions of COBOL, the American National Standards Institute (ANSI) developed a standard form of the language in 1968. This version was known as American National Standard (ANS) COBOL.
In 1974, ANSI published a revised version of (ANS) COBOL, containing a number of features that were not in the 1968 version. In 1985, ANSI published still another revised version that had new features not in the 1974 standard. The language continues to evolve today. Object-oriented COBOL is a subset of COBOL 97, which is the fourth edition in the continuing evolution of ANSI/ISO standard COBOL. COBOL 97 includes conventional improvements as well as object-oriented features.
Like the C++ programming language, object-oriented COBOL compilers are available even as the language moves toward standardization.
Significant Language Features
COBOL, long associated with green screens, core dumps, and traditional mainframe connections, may at first glance seem at odds with object technology, push-button graphical interfaces, and interactive development environments. This perceived incongruity, however, is more a reflection of the mainframe’s ability to keep pace with the innovations of desktop and client-server computing than a flaw in the COBOL language.
Areas of Application
COBOL is ideally suited for the solution of business problems. For example, if a company wanted to keep track of its employees’ annual wages, COBOL would be ideal language for implementation. It is interesting to note that COBOL was the first programming language whose use was mandated by the Department of Defense.
Source Code: (Hello World)
000100 IDENTIFICATION DIVISION.
000200 PROGRAM-ID. HELLOWORLD.
000500 ENVIRONMENT DIVISION.
000600 CONFIGURATION SECTION.
000700 SOURCE-COMPUTER. RM-COBOL.
000800 OBJECT-COMPUTER. RM-COBOL.
001000 DATA DIVISION.
001100 FILE SECTION.
100000 PROCEDURE DIVISION.
100200 MAIN-LOGIC SECTION.
100400 DISPLAY " " LINE 1 POSITION 1 ERASE EOS.
100500 DISPLAY "Hello world!" LINE 15 POSITION 10.
100600 STOP RUN.
This program was tested and run using the RM/1 COBOL compiler. This program demonstrates the text output function of the COBOL programming language by displaying the message "Hello world!".