HOME

TheInfoList



OR:

COMAL (''Common Algorithmic Language'') is a computer
programming language A programming language is a system of notation for writing computer programs. Most programming languages are text-based formal languages, but they may also be graphical. They are a kind of computer language. The description of a programming ...
developed in
Denmark ) , song = ( en, "King Christian stood by the lofty mast") , song_type = National and royal anthem , image_map = EU-Denmark.svg , map_caption = , subdivision_type = Sovereign state , subdivision_name = Danish Realm, Kingdom of Denmark ...
by Børge R. Christensen and Benedict Løfstedt and originally released in 1975. COMAL was one of the few
structured programming Structured programming is a programming paradigm aimed at improving the clarity, quality, and development time of a computer program by making extensive use of the structured control flow constructs of selection ( if/then/else) and repetition ( ...
languages that was available for and comfortably usable on
8-bit In computer architecture, 8-bit Integer (computer science), integers or other Data (computing), data units are those that are 8 bits wide (1 octet (computing), octet). Also, 8-bit central processing unit (CPU) and arithmetic logic unit (ALU) arc ...
home computers. It was based on the seminal
BASIC programming language BASIC (Beginners' All-purpose Symbolic Instruction Code) is a family of General-purpose programming language, general-purpose, high-level programming languages designed for ease of use. Dartmouth BASIC, The original version was created by John ...
, adding multi-line statements and well-defined
subroutine In computer programming, a function or subroutine is a sequence of program instructions that performs a specific task, packaged as a unit. This unit can then be used in programs wherever that particular task should be performed. Functions may ...
s among other additions. "COMAL Kernel Syntax & Semantics" contains the formal definition of the language. Further extensions are common to many implementations.


Design

COMAL was created as a mixture of the prevalent educational programming languages of the time,
BASIC BASIC (Beginners' All-purpose Symbolic Instruction Code) is a family of general-purpose, high-level programming languages designed for ease of use. The original version was created by John G. Kemeny and Thomas E. Kurtz at Dartmouth College ...
, Pascal, and, at least in the
Commodore Commodore may refer to: Ranks * Commodore (rank), a naval rank ** Commodore (Royal Navy), in the United Kingdom ** Commodore (United States) ** Commodore (Canada) ** Commodore (Finland) ** Commodore (Germany) or ''Kommodore'' * Air commodore ...
and
Compis Compis (''COMPuter I Skolan'', also a pun on the colloquial Swedish word ''kompis'' meaning comrade or buddy) was a computer system intended for the general educational system in Sweden and sold to Swedish schools beginning in 1984 through the di ...
versions, the
turtle graphics In computer graphics, turtle graphics are vector graphics using a relative cursor (the "turtle") upon a Cartesian plane (x and y axis). Turtle graphics is a key feature of the Logo programming language. Overview The turtle has three attribut ...
of
Logo A logo (abbreviation of logotype; ) is a graphic mark, emblem, or symbol used to aid and promote public identification and recognition. It may be of an abstract or figurative design or include the text of the name it represents as in a wordma ...
. The language was meant to introduce
structured programming Structured programming is a programming paradigm aimed at improving the clarity, quality, and development time of a computer program by making extensive use of the structured control flow constructs of selection ( if/then/else) and repetition ( ...
elements in an environment where BASIC would normally be used. With the benefit of hindsight, COMAL looks like a Structured BASIC that has reasonably well-written, vendor neutral, free, standards. It is never necessary to use GOTO, and line numbers are purely for editing purposes rather than flow control. Note, however, that the standardised language only supports control structuring, not data structuring such as records or structs (commercial implementations such as UniCOMAL 3 supported this as an extension).


History

COMAL was originally developed in
Denmark ) , song = ( en, "King Christian stood by the lofty mast") , song_type = National and royal anthem , image_map = EU-Denmark.svg , map_caption = , subdivision_type = Sovereign state , subdivision_name = Danish Realm, Kingdom of Denmark ...
by mathematics teacher Børge R. Christensen. The school in which he taught had received a
Data General NOVA The Data General Nova is a series of 16-bit minicomputers released by the American company Data General. The Nova family was very popular in the 1970s and ultimately sold tens of thousands of units. The first model, known simply as "Nova", was ...
1200 minicomputer in 1972, with the expectation that the school would begin to teach
computer science Computer science is the study of computation, automation, and information. Computer science spans theoretical disciplines (such as algorithms, theory of computation, information theory, and automation) to Applied science, practical discipli ...
. Christensen, who had taken a short course on the subject at university, was expected to lead the program and to maintain the computer system. The NOVA 1200 was supplied with Data General Extended BASIC, and Christensen quickly became frustrated with the way in which the unstructured language led students to write low-quality code that was difficult to read and thus mark. Christensen met with computer scientist Benedict Løfstedt, who encouraged him to read ''
Systematic Programming Niklaus Emil Wirth (born 15 February 1934) is a Swiss computer scientist. He has designed several programming languages, including Pascal, and pioneered several classic topics in software engineering. In 1984, he won the Turing Award, generally ...
'', the then-new book on programming language design by
Niklaus Wirth Niklaus Emil Wirth (born 15 February 1934) is a Swiss computer scientist. He has designed several programming languages, including Pascal (programming language), Pascal, and pioneered several classic topics in software engineering. In 1984, he w ...
, the creator of Pascal. Christensen was impressed, but found that he could not use Pascal directly, as it lacked the interactive
shell Shell may refer to: Architecture and design * Shell (structure), a thin structure ** Concrete shell, a thin shell of concrete, usually with no interior columns or exterior buttresses ** Thin-shell structure Science Biology * Seashell, a hard o ...
that made BASIC so easy for students to develop with. Over the next six months Christensen and Løfstedt corresponded by mail to design an alternative to BASIC which retained its interactive elements but added structured elements from Pascal. By 1974 the language's definition was complete but Christensen was unsuccessful in attracting interest from software firms in developing an implementation. He therefore worked with two of his students, to whom he had taught NOVA 1200
machine language In computer programming, machine code is any low-level programming language, consisting of machine language instructions, which are used to control a computer's central processing unit (CPU). Each instruction causes the CPU to perform a very ...
, to write an implementation themselves, over another six months. The first proof-of-concept implementation (running a five-line loop) was ready on 5 August 1974, and the first release (on
paper tape Five- and eight-hole punched paper tape Paper tape reader on the Harwell computer with a small piece of five-hole tape connected in a circle – creating a physical program loop Punched tape or perforated paper tape is a form of data storage ...
, as this was what the NOVA 1200 used for
input-output In computing, input/output (I/O, or informally io or IO) is the communication between an information processing system, such as a computer, and the outside world, possibly a human or another information processing system. Inputs are the signals ...
) was ready in February 1975. Development costs had been around . Only now did the system (which had previously used an internal Danish name) pick up the name ''COMAL'', for ''Common Algorithmic Language'', inspired by
ALGOL ALGOL (; short for "Algorithmic Language") is a family of imperative computer programming languages originally developed in 1958. ALGOL heavily influenced many other languages and was the standard method for algorithm description used by the ...
, with which Christensen had been experimenting. The first release was therefore named ''COMAL 75''. Christensen subsequently wrote a textbook on the language which evolved into ''Beginning COMAL''. In 1978, Christensen began to adapt COMAL such that it would run on
microcomputer A microcomputer is a small, relatively inexpensive computer having a central processing unit (CPU) made out of a microprocessor. The computer also includes memory and input/output (I/O) circuitry together mounted on a printed circuit board (PC ...
s, which were becoming available, worried that without such an implementation he would be required to teach and use BASIC again as Danish schools acquired the new machines. By 1980 a version of COMAL developed in conjection with a college group was able to run on the
Zilog Z80 The Z80 is an 8-bit microprocessor introduced by Zilog as the startup company's first product. The Z80 was conceived by Federico Faggin in late 1974 and developed by him and his 11 employees starting in early 1975. The first working samples wer ...
, and thus ''COMAL 80'' was released. Around the same time, a Danish firm introduced the
Comet A comet is an icy, small Solar System body that, when passing close to the Sun, warms and begins to release gases, a process that is called outgassing. This produces a visible atmosphere or coma, and sometimes also a tail. These phenomena ar ...
, a very capable microcomputer for the time, which would be the first machine to run a version of what would look like the later COMAL releases. Christensen subsequently stepped back from COMAL development around 1980-81, which was handed over to groups including UniComal, started by Mogens Kjaer, who had written to Christensen with critiques of COMAL and subsequently
ported In software engineering, porting is the process of adapting software for the purpose of achieving some form of execution in a computing environment that is different from the one that a given program (meant for such execution) was originally desi ...
it to the
Commodore PET The Commodore PET is a line of personal computers produced starting in 1977 by Commodore International. A single all-in-one case combines a MOS Technology 6502 microprocessor, Commodore BASIC in read-only memory, keyboard, monochrome monitor, an ...
for release 0.14. At this time, Danish schools insisted that COMAL be available on any microcomputer they purchased. In the early 1980s,
Apple Computer Apple Inc. is an American multinational technology company headquartered in Cupertino, California, United States. Apple is the largest technology company by revenue (totaling in 2021) and, as of June 2022, is the world's biggest company b ...
won a contract to supply
Apple II The Apple II (stylized as ) is an 8-bit home computer and one of the world's first highly successful mass-produced microcomputer products. It was designed primarily by Steve Wozniak; Jerry Manock developed the design of Apple II's foam-m ...
computers running
CP/M CP/M, originally standing for Control Program/Monitor and later Control Program for Microcomputers, is a mass-market operating system created in 1974 for Intel 8080/ 85-based microcomputers by Gary Kildall of Digital Research, Inc. Initial ...
and COMAL to Irish secondary schools. It was popular for education and some textbooks were locally written. In 1984
Acornsoft Acornsoft was the software arm of Acorn Computers, and a major publisher of software for the BBC Micro and Acorn Electron. As well as games, it also produced a large number of educational titles, extra computer languages and business and util ...
released a COMAL implementation, by David Christensen, Jim Warwick and David Evers, for their 8-bit
BBC Micro The British Broadcasting Corporation Microcomputer System, or BBC Micro, is a series of microcomputers and associated peripherals designed and built by Acorn Computers in the 1980s for the BBC Computer Literacy Project. Designed with an emphas ...
and
Acorn Electron The Acorn Electron (nicknamed the Elk inside Acorn and beyond) was a lower-cost alternative to the BBC Micro educational/ home computer, also developed by Acorn Computers Ltd, to provide many of the features of that more expensive machine at a ...
computers (with a manual by Paul Christensen and Roy Thornton) Between 1984-1987 TeleNova, a subsidiary of the industrial arm of the Swedish Telecoms system, manufactured a
desktop PC A desktop computer (often abbreviated desktop) is a personal computer designed for regular use at a single location on or near a desk due to its size and power requirements. The most common configuration has a case that houses the power supply, ...
called "
Compis Compis (''COMPuter I Skolan'', also a pun on the colloquial Swedish word ''kompis'' meaning comrade or buddy) was a computer system intended for the general educational system in Sweden and sold to Swedish schools beginning in 1984 through the di ...
" for the educational sector. An enhanced version of COMAL was supplied as the standard programming language for this PC. Versions were created for both
CP/M-86 CP/M-86 was a version of the CP/M operating system that Digital Research (DR) made for the Intel 8086 and Intel 8088. The system commands are the same as in CP/M-80. Executable files used the relocatable .CMD file format. Digital Research als ...
and
MS-DOS MS-DOS ( ; acronym for Microsoft Disk Operating System, also known as Microsoft DOS) is an operating system for x86-based personal computers mostly developed by Microsoft. Collectively, MS-DOS, its rebranding as IBM PC DOS, and a few ope ...
. The latter version is available for
Windows XP Windows XP is a major release of Microsoft's Windows NT operating system. It was released to manufacturing on August 24, 2001, and later to retail on October 25, 2001. It is a direct upgrade to its predecessors, Windows 2000 for high-end and ...
. The (Swedish) reference manual is . In 1990 Thomas Lundy and Rory O'Sullivan produced the definitive text on COMAL Programming. They matched and compared COMAL with BBC Structured Basic. As of 2016 COMAL is still actively in use as an educational programming language. Some high schools in the United Kingdom continue to use it to teach the subject of Computing.


Availability

COMAL was available for: *
BBC Micro The British Broadcasting Corporation Microcomputer System, or BBC Micro, is a series of microcomputers and associated peripherals designed and built by Acorn Computers in the 1980s for the BBC Computer Literacy Project. Designed with an emphas ...
*
Commodore PET The Commodore PET is a line of personal computers produced starting in 1977 by Commodore International. A single all-in-one case combines a MOS Technology 6502 microprocessor, Commodore BASIC in read-only memory, keyboard, monochrome monitor, an ...
(
public domain software Public-domain software is software that has been placed in the public domain, in other words, software for which there is absolutely no ownership such as copyright, trademark, or patent. Software in the public domain can be modified, distributed, ...
) *
Commodore 64 The Commodore 64, also known as the C64, is an 8-bit home computer introduced in January 1982 by Commodore International (first shown at the Consumer Electronics Show, January 7–10, 1982, in Las Vegas). It has been listed in the Guinness ...
(public domain software) *
Commodore 128 The Commodore 128, also known as the C128, C-128, C= 128,The "C=" represents the graphical part of the logo. is the last 8-bit home computer that was commercially released by Commodore Business Machines (CBM). Introduced in January 1985 at the ...
*
Amiga Amiga is a family of personal computers introduced by Commodore in 1985. The original model is one of a number of mid-1980s computers with 16- or 32-bit processors, 256 KB or more of RAM, mouse-based GUIs, and significantly improved graphi ...
*
Compis Compis (''COMPuter I Skolan'', also a pun on the colloquial Swedish word ''kompis'' meaning comrade or buddy) was a computer system intended for the general educational system in Sweden and sold to Swedish schools beginning in 1984 through the di ...
/ Scandis *
CP/M CP/M, originally standing for Control Program/Monitor and later Control Program for Microcomputers, is a mass-market operating system created in 1974 for Intel 8080/ 85-based microcomputers by Gary Kildall of Digital Research, Inc. Initial ...
*
IBM PC The IBM Personal Computer (model 5150, commonly known as the IBM PC) is the first microcomputer released in the IBM PC model line and the basis for the IBM PC compatible de facto standard. Released on August 12, 1981, it was created by a team ...
*
Tiki 100 Tiki-100 was a desktop home/personal computer manufactured by Tiki Data of Oslo, Norway. The computer was launched in the spring of 1984 under the original name Kontiki-100, and was first and foremost intended for the emerging educational sector ...
*
ZX Spectrum The ZX Spectrum () is an 8-bit computing, 8-bit home computer that was developed by Sinclair Research. It was released in the United Kingdom on 23 April 1982, and became Britain's best-selling microcomputer. Referred to during development as t ...
*
Grundy NewBrain The Grundy NewBrain was a microcomputer sold in the early 1980s by Grundy Business Systems Ltd of Teddington and Cambridge, England. Beginnings The NewBrain project was started in 1978 when Sinclair Radionics began design work with Mike Wak ...
*
Windows XP Windows XP is a major release of Microsoft's Windows NT operating system. It was released to manufacturing on August 24, 2001, and later to retail on October 25, 2001. It is a direct upgrade to its predecessors, Windows 2000 for high-end and ...


Examples

* "Hello, world!" *: PRINT "HELLO, WORLD!" * Conditions *: IF condition THEN instructions ENDIF * Loops *: FOR number:= 1 TO 1000 DO PRINT number ENDFOR * Print statements with variables *: INPUT "What's your favourite number? " :nmr# PAGE PRINT "Your favourite number is " ; nmr#


See also

*
Action! (programming language) Action! is a procedural programming language and integrated development environment written by Clinton Parker for the Atari 8-bit family. The language, which is similar to ALGOL, compiles to high-performance code for the MOS Technologies 6502 ...


References


Further reading

* Thomas Lundy & Rory O'Sullivan: ''Beginning Structured Programming in BASIC and COMAL'', 1990 * Roy Atherton: ''Structured programming with COMAL.'' Horwood, Chichester 1982, . * * Børge R. Christensen: ''Beginning Comal.'' Horwood, Chichester 1982, . * Børge R. Christensen:
COMAL Reference Guide
'' Toronto PET Users Group, Toronto Ontario, . * * Len Lindsay:
COMAL handbook
'' Reston Publishing, Reston, VA, 1983, . * Gordon Shigley:
COMAL Workbook
'' Comal Users Group, USA, 1985, .


External links


OpenCOMAL
for
Unix Unix (; trademarked as UNIX) is a family of multitasking, multiuser computer operating systems that derive from the original AT&T Unix, whose development started in 1969 at the Bell Labs research center by Ken Thompson, Dennis Ritchie, and ot ...
,
MS-DOS MS-DOS ( ; acronym for Microsoft Disk Operating System, also known as Microsoft DOS) is an operating system for x86-based personal computers mostly developed by Microsoft. Collectively, MS-DOS, its rebranding as IBM PC DOS, and a few ope ...
and
Win32 The Windows API, informally WinAPI, is Microsoft's core set of application programming interfaces (APIs) available in the Microsoft Windows operating systems. The name Windows API collectively refers to several different platform implementations th ...

A fork of the above
for standards-compliant
Unix Unix (; trademarked as UNIX) is a family of multitasking, multiuser computer operating systems that derive from the original AT&T Unix, whose development started in 1969 at the Bell Labs research center by Ken Thompson, Dennis Ritchie, and ot ...
, mainly
Linux Linux ( or ) is a family of open-source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991, by Linus Torvalds. Linux is typically packaged as a Linux distribution, which ...
and
Mac OS X macOS (; previously OS X and originally Mac OS X) is a Unix operating system developed and marketed by Apple Inc. since 2001. It is the primary operating system for Apple's Mac (computer), Mac computers. Within the market of ...

UniComal 3.11
packaged to run under
DOSBox DOSBox is a free and open-source emulator which runs software for MS-DOS compatible disk operating systems—primarily video games. It was first released in 2002, when DOS technology was becoming obsolete. Its adoption for running DOS games i ...

Description of COMAL, versions, and characteristics
(1984) {{Authority control Programming languages Educational programming languages Structured programming languages Procedural programming languages Programming languages created in 1973