ALGOL 68
Encyclopedia
ALGOL 68 is
an imperative
Imperative programming
In computer science, imperative programming is a programming paradigm that describes computation in terms of statements that change a program state...

 computer
Computer programming
Computer programming is the process of designing, writing, testing, debugging, and maintaining the source code of computer programs. This source code is written in one or more programming languages. The purpose of programming is to create a program that performs specific operations or exhibits a...


programming language
Programming language
A programming language is an artificial language designed to communicate instructions to a machine, particularly a computer. Programming languages can be used to create programs that control the behavior of a machine and/or to express algorithms precisely....

 that was conceived as a successor to the
ALGOL 60
ALGOL 60
ALGOL 60 is a member of the ALGOL family of computer programming languages. It gave rise to many other programming languages, including BCPL, B, Pascal, Simula, C, and many others. ALGOL 58 introduced code blocks and the begin and end pairs for delimiting them...

 programming language, designed with the goal of a
much wider scope of application and more rigorously defined syntax
and semantics.

Contributions of ALGOL 68 to the field of computer science
Computer science
Computer science or computing science is the study of the theoretical foundations of information and computation and of practical techniques for their implementation and application in computer systems...


are deep and wide ranging, although some of them were not
publicly identified until they were passed, in one form or another,
to one of many subsequently developed programming languages.

ALGOL 68 features include expression-based syntax,
user-declared types & structures/tagged-unions,
a reference model of variables & reference parameters,
string & array & matrix slicing
and also concurrency.

ALGOL 68 was designed by IFIP Working Group 2.1
IFIP Working Group 2.1
IFIP Working Group 2.1 on Algorithmic Languages and Calculi is a working group of the International Federation for Information Processing ....

.
On December 20, 1968 the language was formally adopted by Working
Group 2.1 and subsequently approved for publication by the General
Assembly of IFIP.

ALGOL 68 was defined using a two-level grammar formalism invented
by Adriaan van Wijngaarden
Adriaan van Wijngaarden
Adriaan van Wijngaarden was an important mathematician and computer scientist who is considered by many to have been the founding father of informatica in the Netherlands...

. Van Wijngaarden grammar
Van Wijngaarden grammar
In computer science, a Van Wijngaarden grammar is a two-level grammar which provides a technique to define potentially infinite context-free grammars in a finite number of rules...

s use a
context-free grammar
Context-free grammar
In formal language theory, a context-free grammar is a formal grammar in which every production rule is of the formwhere V is a single nonterminal symbol, and w is a string of terminals and/or nonterminals ....

 to generate an infinite set of productions
that will recognize a particular ALGOL 68 program; notably, they are
able to express the kind of requirements that in many other programming
language standards are labeled "semantics" and have to be expressed in
ambiguity-prone natural language prose, and then implemented in compilers
as ad hoc code attached to the formal language parser.
The main aims and principles of design of ALGOL 68:
  1. Completeness and clarity of design,
  2. Orthogonal
    Orthogonality
    Orthogonality occurs when two things can vary independently, they are uncorrelated, or they are perpendicular.-Mathematics:In mathematics, two vectors are orthogonal if they are perpendicular, i.e., they form a right angle...

     design,
  3. Security,
  4. Efficiency:
    • Static mode checking
    • Mode-independent parsing
    • Independent compilation
    • Loop optimization
    • Representations - in minimal & larger character sets



ALGOL 68 has been criticized, most prominently by some members of its design committee such as C. A. R. Hoare
C. A. R. Hoare
Sir Charles Antony Richard Hoare , commonly known as Tony Hoare or C. A. R. Hoare, is a British computer scientist best known for the development of Quicksort, one of the world's most widely used sorting algorithms...

 and Edsger Dijkstra
Edsger Dijkstra
Edsger Wybe Dijkstra ; ) was a Dutch computer scientist. He received the 1972 Turing Award for fundamental contributions to developing programming languages, and was the Schlumberger Centennial Chair of Computer Sciences at The University of Texas at Austin from 1984 until 2000.Shortly before his...

, for abandoning the simplicity of ALGOL 60
ALGOL 60
ALGOL 60 is a member of the ALGOL family of computer programming languages. It gave rise to many other programming languages, including BCPL, B, Pascal, Simula, C, and many others. ALGOL 58 introduced code blocks and the begin and end pairs for delimiting them...

 becoming a vehicle for complex or overly general ideas, and doing little to make the compiler
Compiler
A compiler is a computer program that transforms source code written in a programming language into another computer language...

 writer's task easy, in contrast to deliberately simple contemporaries (and competitors) such as C
C (programming language)
C is a general-purpose computer programming language developed between 1969 and 1973 by Dennis Ritchie at the Bell Telephone Laboratories for use with the Unix operating system....

, S-algol
S-algol
S-algol is a computer programming language derivative of ALGOL 60 developed at the University of St. Andrews in 1979 by Ron Morrison. The language was developed as his PhD thesis as a modification of ALGOL to contain orthogonal datatypes. Ron Morrison would go on to become professor at the...

 and Pascal.

In the 1973 revision, certain features - such as proceduring, gommas and formal bounds - were omitted. c.f. The language of the unrevised report.

Though European defence agencies (in Britain Royal Signals and Radar Establishment
Royal Signals and Radar Establishment
The Royal Signals and Radar Establishment was a scientific research establishment within the Ministry of Defence of the United Kingdom, located primarily at Malvern in Worcestershire. It was formed in 1976 in an amalgamation of earlier research establishments including the Royal Radar Establishment...

 - RSRE) promoted the use of ALGOL 68 for its expected security advantages, the American side of the NATO alliance decided to develop a different project, the Ada programming language, making its use obligatory for U.S. defense contracts.

Steve Bourne, who was on the Algol 68 revision committee, took some of its ideas to his Bourne shell
Bourne shell
The Bourne shell, or sh, was the default Unix shell of Unix Version 7 and most Unix-like systems continue to have /bin/sh - which will be the Bourne shell, or a symbolic link or hard link to a compatible shell - even when more modern shells are used by most users.Developed by Stephen Bourne at AT&T...

 (and thereby, to descendant shell
Unix shell
A Unix shell is a command-line interpreter or shell that provides a traditional user interface for the Unix operating system and for Unix-like systems...

s such as Bash) and to C
C (programming language)
C is a general-purpose computer programming language developed between 1969 and 1973 by Dennis Ritchie at the Bell Telephone Laboratories for use with the Unix operating system....

 (and thereby to descendants such as C++
C++
C++ is a statically typed, free-form, multi-paradigm, compiled, general-purpose programming language. It is regarded as an intermediate-level language, as it comprises a combination of both high-level and low-level language features. It was developed by Bjarne Stroustrup starting in 1979 at Bell...

).

The complete history of the project can be found in C.H. Lindsey's A History of ALGOL 68.

For a full length treatment of the language, see Programming Algol 68 Made Easy by Dr. Sian Leitch, or Learning Algol 68 Genie by Dr. Marcel van der Veer which includes the Revised Report.

Time-line of ALGOL 68

Year Event Contributor
Mar 1959 ALGOL Bulletin
ALGOL Bulletin
The ALGOL Bulletin was published by the Association for Computing Machinery regarding the ALGOL 60 and ALGOL 68 programming languages from March 1959 till August 1988.-Time-line of ALGOL Bulletin:- References :...

 Issue 1 (First)
Peter Naur
Peter Naur
Peter Naur is a Danish pioneer in computer science and Turing award winner. His last name is the N in the BNF notation , used in the description of the syntax for most programming languages...

 / ACM
Association for Computing Machinery
The Association for Computing Machinery is a learned society for computing. It was founded in 1947 as the world's first scientific and educational computing society. Its membership is more than 92,000 as of 2009...

Feb 1968 Draft Report(DR) Published IFIP Working Group 2.1
IFIP Working Group 2.1
IFIP Working Group 2.1 on Algorithmic Languages and Calculi is a working group of the International Federation for Information Processing ....

Mar 1968 Algol 68 Final Report(FR) Presented at Munich Meeting IFIP Working Group 2.1
Jun 1968 Meeting in Tirrenia, Italy IFIP Working Group 2.1
Aug 1968 Meeting in North Berwick, Scotland IFIP Working Group 2.1
Dec 1968 Algol 68 Final Report(FR) Presented at Munich Meeting IFIP Working Group 2.1
Apr 1970 ALGOL 68R
ALGOL 68R
ALGOL 68-R was the first implementation of the Algorithmic language ALGOL 68.In December 1968 the report on the Algorithmic language ALGOL 68 was published. On 20–24 July 1970 a working conference was arranged by the IFIP to discuss the problems of implementation of the language, a small team from...

(R) under GEORGE 3
GEORGE (operating system)
GEORGE was the name given to a series of operating systems released by International Computers and Tabulators in the 1960s, for the ICT 1900 series of computers....

 on an ICL 1907F
ICT 1900 series
ICT 1900 was the name given to a series of mainframe computers released by International Computers and Tabulators and later International Computers Limited during the 1960s and '70s...

.
Royal Signals and Radar Est.
Sep 1973 Revised Report (RR)Published IFIP Working Group 2.1
1975 ALGOL 68C
ALGOL 68C
The ALGOL68C computer programming language compiler was developed for the CHAOS OS for the CAP capability computer at Cambridge University in 1971 by Stephen Bourne and Michael Guy as a dialect of ALGOL 68. Other early contributors were Andrew D. Birrell and Ian Walker.The initial compiler was...

(C) - transportable compiler (zcode VM
Virtual machine
A virtual machine is a "completely isolated guest operating system installation within a normal host operating system". Modern virtual machines are implemented with either software emulation or hardware virtualization or both together.-VM Definitions:A virtual machine is a software...

)
S. Bourne, Andrew Birrell, and Michael Guy
Jun 1977 Strathclyde ALGOL 68 conference, Scotland ACM
May 1978 Proposals for ALGOL H - A Superlanguage of ALGOL 68 A. P. Black, V. J. Rayward-Smith
1984 Full ALGOL 68S
ALGOL 68S
ALGOL 68S was designed as a subset of ALGOL 68 in order to permit single-pass compilation. It was mostly for numerical computation.-Implementations:...

(S) compiler for Sun, SPARC, and PCs
C.H.Lindsey ea, Manchester
Aug 1988 ALGOL Bulletin
ALGOL Bulletin
The ALGOL Bulletin was published by the Association for Computing Machinery regarding the ALGOL 60 and ALGOL 68 programming languages from March 1959 till August 1988.-Time-line of ALGOL Bulletin:- References :...

 Issue 52 (last)
Ed. C. H. Lindsey / ACM
May 1997 Algol68 S(S) published on the internet Charles H. Lindsey
Nov 2001 ALGOL 68G
ALGOL 68G
ALGOL68G or Algol 68 Genie is a recent ALGOL 68 compiler-interpreter. ALGOL68G is a nearly full implementation of ALGOL 68 as defined by the Revised Report and also implements partial parametrisation, which is an extension of ALGOL 68. After successful parsing of an entire source program, the...

(G) released (GNU GPL open source licensing)
Marcel van der Veer

The Algorithmic Language ALGOL 68 Reports

  • Mar. 1968: Draft Report on the Algorithmic Language ALGOL 68 - Edited by: A. van Wijngaarden
    Adriaan van Wijngaarden
    Adriaan van Wijngaarden was an important mathematician and computer scientist who is considered by many to have been the founding father of informatica in the Netherlands...

    , B.J. Mailloux
    Barry J. Mailloux
    Barry James Mailloux obtained his M.Sc in Numerical Analysis in 1963.From 1966 he studied at Amsterdam's Mathematisch Centrum under Adriaan van Wijngaarden....

    , J.E.L. Peck
    John E. L. Peck
    John E. L. Peck was the first permanent Head of Department of Computer Science at the University of British Columbia. He remained the Head of Department from 1969 to 1977....

     and C.H.A. Koster.

  • Oct. 1968: Penultimate Draft Report on the Algorithmic Language ALGOL 68 - Chapters 1-9 Chapters 10-12 - Edited by: A. van Wijngaarden, B.J. Mailloux, J.E.L. Peck and C.H.A. Koster.
  • Dec. 1968: Report on the Algorithmic Language ALGOL 68 - Offprint from Numerische Mathematik, 14, 79-218 (1969); Springer-Verlag. - Edited by: A. van Wijngaarden, B.J. Mailloux, J.E.L. Peck and C.H.A. Koster.
    • WG 2.1 members active in the original design of ALGOL 68:. Friedrich L. Bauer
      Friedrich L. Bauer
      Friedrich Ludwig Bauer is a German computer scientist and professor emeritus at Technical University of Munich.-Life:...

       • Hans Bekic • Edsger Dijkstra
      Edsger Dijkstra
      Edsger Wybe Dijkstra ; ) was a Dutch computer scientist. He received the 1972 Turing Award for fundamental contributions to developing programming languages, and was the Schlumberger Centennial Chair of Computer Sciences at The University of Texas at Austin from 1984 until 2000.Shortly before his...

      † • Fraser Duncan† • Jan Garwick† • Gerhard Goos  • Tony Hoare† • Peter Zilahy Ingerman • Kees Koster • Peter Landin • Charles Lindsey • Barry Mailloux • John McCarthy
      John McCarthy (computer scientist)
      John McCarthy was an American computer scientist and cognitive scientist. He coined the term "artificial intelligence" , invented the Lisp programming language and was highly influential in the early development of AI.McCarthy also influenced other areas of computing such as time sharing systems...

       • Jack Merner • Peter Naur
      Peter Naur
      Peter Naur is a Danish pioneer in computer science and Turing award winner. His last name is the N in the BNF notation , used in the description of the syntax for most programming languages...

      ‡ • Manfred Paul • John Peck
      John E. L. Peck
      John E. L. Peck was the first permanent Head of Department of Computer Science at the University of British Columbia. He remained the Head of Department from 1969 to 1977....

       • Willem van der Poel
      Willem van der Poel
      Willem Louis van der Poel is a pioneering Dutch computer scientist, who is known for designing the ZEBRA computer. In 1950 he obtained an engineering degree in applied science at Delft University of Technology. In 1956 he obtained his PhD degree from the University of Amsterdam...

       • Brian Randell
      Brian Randell
      Brian Randell is a British computer scientist, and Emeritus Professor at the School of Computing Science, Newcastle University, U.K. He specializes in research in software fault tolerance and dependability, and is a noted authority on the early prior to 1950 history of computers.- Biography...

      † • Doug Ross
      Douglas T. Ross
      Douglas Taylor Ross was an American computer scientist pioneer, and Chairman of SofTech, Inc.. He is most famous for originating the term CAD for computer-aided design, and is consider to be the father of Automatically Programmed Tools a language to drive numerically controlled manufacturing.-...

       • Klaus Samelson
      Klaus Samelson
      Klaus Samelson was a German mathematician, physicist, and computer pioneer in the area of programming language translation and push-pop stack algorithms for sequential formula translation on computers.- Early life :...

        • Gerhard Seegmüller† • Michel Sintzoff • Wlad Turski† • Aad van Wijngaarden • Niklaus Wirth
      Niklaus Wirth
      Niklaus Emil Wirth is a Swiss computer scientist, best known for designing several programming languages, including Pascal, and for pioneering several classic topics in software engineering. In 1984 he won the Turing Award for developing a sequence of innovative computer languages.-Biography:Wirth...

      ‡ • Mike Woodger† • Nobuo Yoneda
      Nobuo Yoneda
      was a Japanese mathematician and computer scientist. The Yoneda lemma in category theory is named after him. In computer science, he is known for his work on ALGOL dialects.-References:...

      ; †Signatories to the Minority Report. ‡Resigned after [MR 93].
  • Sep 1973: Revised Report on the Algorithmic Language Algol 68 - Springer-Verlag 1976 - Edited by: A. van Wijngaarden, B.J. Mailloux, J.E.L. Peck
    John E. L. Peck
    John E. L. Peck was the first permanent Head of Department of Computer Science at the University of British Columbia. He remained the Head of Department from 1969 to 1977....

    , C.H.A. Koster, M. Sintzoff, C.H. Lindsey, L.G.L.T. Meertens
    Lambert Meertens
    Lambert Guillaume Louis Théodore Meertens is a Dutch computer scientist and professor.While still a student at the Ignatius Gymnasium in Amsterdam, Meertens designed a computer, together with his classmate Kees Koster....

     and R.G. Fisker.

Standardization

On December 20, 1968 the "Final Report" (MR 101) was adopted by the Working Group, then subsequently approved by the General Assembly of UNESCO
UNESCO
The United Nations Educational, Scientific and Cultural Organization is a specialized agency of the United Nations...

's IFIP for publication. Translations of the standard were made for Russian
Russian language
Russian is a Slavic language used primarily in Russia, Belarus, Uzbekistan, Kazakhstan, Tajikistan and Kyrgyzstan. It is an unofficial but widely spoken language in Ukraine, Moldova, Latvia, Turkmenistan and Estonia and, to a lesser extent, the other countries that were once constituent republics...

, German
German language
German is a West Germanic language, related to and classified alongside English and Dutch. With an estimated 90 – 98 million native speakers, German is one of the world's major languages and is the most widely-spoken first language in the European Union....

, French
French language
French is a Romance language spoken as a first language in France, the Romandy region in Switzerland, Wallonia and Brussels in Belgium, Monaco, the regions of Quebec and Acadia in Canada, and by various communities elsewhere. Second-language speakers of French are distributed throughout many parts...

 and Bulgarian
Bulgarian language
Bulgarian is an Indo-European language, a member of the Slavic linguistic group.Bulgarian, along with the closely related Macedonian language, demonstrates several linguistic characteristics that set it apart from all other Slavic languages such as the elimination of case declension, the...

, and then later Japanese
Japanese language
is a language spoken by over 130 million people in Japan and in Japanese emigrant communities. It is a member of the Japonic language family, which has a number of proposed relationships with other languages, none of which has gained wide acceptance among historical linguists .Japanese is an...

. The standard was also made available in Braille
Braille
The Braille system is a method that is widely used by blind people to read and write, and was the first digital form of writing.Braille was devised in 1825 by Louis Braille, a blind Frenchman. Each Braille character, or cell, is made up of six dot positions, arranged in a rectangle containing two...

.
Subsequently ALGOL 68 became one of the GOST
GOST
GOST refers to a set of technical standards maintained by the Euro-Asian Council for Standardization, Metrology and Certification , a regional standards organization operating under the auspices of the Commonwealth of Independent States .All sorts of regulated standards are included, with examples...

 standards in Russia.
  • GOST 27974-88 Programming language ALGOL 68 - Язык программирования АЛГОЛ 68
  • GOST 27975-88 Programming language ALGOL 68 extended - Язык программирования АЛГОЛ 68 расширенный

Bold symbols and reserved words

There are 61 such reserved words ( some with "brief symbol" equivalents ) in the standard sub-language:

mode, op, prio, proc,
flex, heap, loc, long, ref, short,
bits, bool, bytes, char, compl, int, real, sema, string, void,
channel, file, format, struct, union,
of, at "@", is ":=:", isnt ":/=:", true, false, empty, nil "∘", skip "~",
co "¢", comment "¢", pr, pragmat,
case in ouse in out esac "( ~ | ~ |: ~ | ~ | ~ )",
for from to by while do od,
if then elif then else fi "( ~ | ~ |: ~ | ~ | ~ )",
par begin end "( ~ )", go to, goto, exit.

Units: Expressions

The basic language construct is the unit. A unit may be a formula, an enclosed clause, a routine text or one of several technically needed constructs (assignation, jump, skip, nihil). The technical term enclosed clause unifies some of the inherently bracketting constructs known as block, do statement, switch statement in other contemporary languages. When keywords are used, generally the reversed character sequence of the introducing keyword is used for terminating the enclosure, eg. ( 'if' ~ then ~ else ~ 'fi', 'case' ~ in ~ out ~ 'esac', for ~ while ~ 'do' ~ 'od'). This feature was reused by Stephen Bourne in the common Unix
Unix
Unix is a multitasking, multi-user computer operating system originally developed in 1969 by a group of AT&T employees at Bell Labs, including Ken Thompson, Dennis Ritchie, Brian Kernighan, Douglas McIlroy, and Joe Ossanna...

 Bourne shell
Bourne shell
The Bourne shell, or sh, was the default Unix shell of Unix Version 7 and most Unix-like systems continue to have /bin/sh - which will be the Bourne shell, or a symbolic link or hard link to a compatible shell - even when more modern shells are used by most users.Developed by Stephen Bourne at AT&T...

. An expression may also yield a multiple value, which is constructed from other values by a collateral clause. This construct just looks like the parameter pack of a procedure call.

mode: Declarations

The basic data type
Data type
In computer programming, a data type is a classification identifying one of various types of data, such as floating-point, integer, or Boolean, that determines the possible values for that type; the operations that can be done on values of that type; the meaning of the data; and the way values of...

s (called modes in ALGOL 68 parlance) are real, int, compl (complex number
Complex number
A complex number is a number consisting of a real part and an imaginary part. Complex numbers extend the idea of the one-dimensional number line to the two-dimensional complex plane by using the number line for the real part and adding a vertical axis to plot the imaginary part...

), bool, char, bits and bytes. For example:

int n = 2;
co n is a fixed constant of 2.co
int m := 3;
co m is a newly created local variable whose value is initially set to 3.
This is short for ref int m = loc int := 3; co
real avogadro = 6.0221415⏨23; co Avogadro's number co
long long real pi = 3.14159 26535 89793 23846 26433 83279 50288 41971 69399 37510;
compl square root of minus one = 0 ⊥ 1


However, the declaration real x; is just syntactic sugar
Syntactic sugar
Syntactic sugar is a computer science term that refers to syntax within a programming language that is designed to make things easier to read or to express....

 for ref real x = loc real;. That is, x is really the constant identifier for a reference to a newly generated local real variable.

Furthermore, instead of defining both float and double, or int and long and short, etc., ALGOL 68 provided modifiers, so that the presently common double would be written as long real or long long real instead, for example. Type queries of the kind of max real and min long int are provided to adapt programs to different implementations.

All variables need to be declared, the declaration does not have to appear prior to the first use.

primitive-declarer: int, real, compl, complexG, bool, char, string, bits, bytes, format, file, pipeG, channel, sema
  • bits - a "packed vector" of bool.
  • bytes - a "packed vector" of char.
  • string - a flexible array of char.
  • sema - a semaphore
    Semaphore (programming)
    In computer science, a semaphore is a variable or abstract data type that provides a simple but useful abstraction for controlling access by multiple processes to a common resource in a parallel programming environment....

     which can be initialised with the operator level.


Other declaration symbols include: flex, heap, loc, ref, long, short, eventS
  • flex - declare the array to be flexible, i.e. it can grow in length on demand.
  • heap - allocate variable some free space from the global heap.
  • loc - allocate variable some free space of the local stack.
  • ref - declare the variable to be a pointer, similar to using "&" in a C++ declaration.
  • long - declare an int, real or compl to be of a longer size.
  • short - declare an int, real or compl to be of a shorter size.


A new mode (type) may be declared using a mode declaration:
int max=99;
mode newtype = [0:9][0:max]struct (
long real a, b, c, short int i, j, k, ref real r
);
This has the similar effect as the following C++ code:
const int max=99;
typedef struct {
double a, b, c; short i, j, k; float *r;
} newtype[9+1][max+1];
Note that for ALGOL 68 only the newtype mode-indication appears to the left of the equals symbol, and most notably the construction is made - and can be read - from left to right without regard to priorities.

Coercions: casting

The coercions produce a coercend from a coercee according to three criteria: the a priori mode of the coercend before the application of any coercion, the a posteriori mode of the coercee required after those coercions, and the syntactic position or "sort" of the coercee. Coercions may be cascaded.

There are six possible coercions, termed "deproceduring", "dereferencing", "uniting", "widening", "rowing" and "voiding". Each Coercion, except "uniting", prescribes a corresponding dynamic effect on the associated values. Hence, a number of primitive actions can be programmed implicitly by coercions.

Context strength - Allowed coercions:
  • soft - deproceduring
  • weak - dereferencing or deproceduring, yielding a name
  • meek - dereferencing or deproceduring
  • firm - meek, followed by uniting
  • strong - firm, followed by widening, rowing or voiding

pr & co: Pragmats and Comments

Pragmats are directives in the program, typically hints to the compiler. eg.
pragmat heap=32 pragmat
pr heap=32 pr

Comments can be inserted in variety of ways:
¢ The original way of adding your 2 cents worth to a program ¢
comment "bold" comment comment
co Style i comment co
# Style ii comment #
£ This is a hash/pound comment for a UK keyboard £

Normally, comments cannot be nested in ALGOL 68. This restriction can be circumvented by using different comment delimiters (e.g. use hash only for temporary code deletions).

Expressions and compound statements

ALGOL 68 being an expression-oriented programming language
Expression-oriented programming languages
An expression-oriented programming language is a programming language where every construction is an expression and thus yields a value. The typical exceptions are macro definitions, preprocessor commands, and declarations, which expression-oriented languages often treat as statements rather than...

, the value returned by an assignment statement is a reference to the destination. Thus, the following is valid ALGOL 68 code:
real half pi, one pi; one pi := 2 * ( half pi := 2 * arc tan(1) )
This notion is present in C
C (programming language)
C is a general-purpose computer programming language developed between 1969 and 1973 by Dennis Ritchie at the Bell Telephone Laboratories for use with the Unix operating system....

 and Perl
Perl
Perl is a high-level, general-purpose, interpreted, dynamic programming language. Perl was originally developed by Larry Wall in 1987 as a general-purpose Unix scripting language to make report processing easier. Since then, it has undergone many changes and revisions and become widely popular...

, among others. Note that half pi is a single identifier, i.e., blanks are ignored even within ALGOL 68 identifiers (effectively avoiding the underscores versus camel case versus all lower-case issues at once, but at the price of introducing a cornucopia of more serious problems in software engineering).

As another example, to express the mathematical idea of a sum of f(i) from i=1 to n, the following ALGOL 68 integer expression suffices:
(int sum := 0; for i to n do sum +:= f(i) od; sum)
Note that, being an integer expression, the former block of code can be used in any context where an integer value can be used. A block of code returns the value of the last expression it evaluated; this idea is present in Lisp
Lisp
A lisp is a speech impediment, historically also known as sigmatism. Stereotypically, people with a lisp are unable to pronounce sibilants , and replace them with interdentals , though there are actually several kinds of lisp...

, among other languages.

Compound statements are all terminated by distinctive (and somewhat reverent) closing brackets:
  • if choice clauses:

if condition then statements [ else statements ] fi
"brief" form of if statement: ( condition | statements | statements )

if condition1 then statements elif condition2 then statements [ else statements ] fi
"brief" form: ( condition1 | statements |: condition2 | statements | statements )
This scheme not only avoids the dangling else
Dangling else
The dangling else is a problem in computer programming in which a seemingly well-defined statement can become ambiguous. In many programming languages one may write conditionally executed code in two forms: the if-then form, and the if-then-else form:...

 problem but also avoids having to use begin and end in embedded statement
Statement (programming)
In computer programming a statement can be thought of as the smallest standalone element of an imperative programming language. A program written in such a language is formed by a sequence of one or more statements. A statement will have internal components .Many languages In computer programming...

 sequences.
  • case choice clauses:

case switch in statements, statements,... [ out statements ] esac
"brief" form: ( switch | statements,statements,... | statements )

case switch1 in statements, statements,... ouse switch2 in statements, statements,... [ out statements ] esac
"brief" form of case statement: ( switch1 | statements,statements,... |: switch2 | statements,statements,... | statements )
Brief choice clause example:
proc days in month = (int year, month)int:
(month|31,
(year%×4=0 ∧ year%×100≠0 ∨ year%×400=0|29|28),
31,30,31,30,31,31,30,31,30,31
);

Bold choice clause example:
proc days in month = (int year, month)int:
case month in 31,
if year mod 4 eq 0 and year mod 100 ne 0 or year mod 400 eq 0 then 29 else 28 fi,
31,30,31,30,31,31,30,31,30,31
esac;
Algol68 allowed the switch to be of either type int or (uniquely) union. The latter allows the enforcing strong typing onto union variables. c.f. union below for example.
  • do
    For loop
    In computer science a for loop is a programming language statement which allows code to be repeatedly executed. A for loop is classified as an iteration statement....

    loop clause:

[ for index ] [ from first ] [ by increment ] [ to last ] [ while condition ] do statements od
The minimum form of a "loop clause" is thus: do statements od
This was considered the "universal" loop, the full syntax is:
for i from 1 by 1 to 3 while i≠4 do ~ od
There are several unusual aspects of the construct:
    • only the do ~ od portion was compulsory, in which case the loop will iterate indefinitely.
    • thus the clause to 100 do ~ od, will iterate only 100 times.
    • the while "syntactic element" allowed a programmer to break from a for loop early. eg

int sum sq:=0;
for i
while
print(("So far:",i,newline));
sum sq≤1000
do
sum sq+:=i↑2
od

Subsequent "extensions" to the standard Algol68 allowed the to syntactic element to be replaced with upto and downto to achieve a small optimisation. The same compilers also incorporated:
  • until(C) - for late loop termination.
  • foreach(S) - for working on arrays in parallel
    Parallel computing
    Parallel computing is a form of computation in which many calculations are carried out simultaneously, operating on the principle that large problems can often be divided into smaller ones, which are then solved concurrently . There are several different forms of parallel computing: bit-level,...

    .


Further examples can be found in the code examples below.

struct, union & [:]: Structures, unions and arrays

ALGOL 68 supports arrays with any number of dimensions, and it allows for the slicing of whole or partial rows or columns.
mode vector = [1:3] real; # vector mode declaration (typedef) #
mode matrix = [1:3,1:3]real; # matrix mode declaration (typedef) #
vector v1 := (1,2,3); # array variable initially (1,2,3) #
[]real v2 = (4,5,6); # constant array, type equivalent to vector, bounds are implied #
op + = (vector a,b) vector: # binary operator definition #
(vector out; for i from ⌊a to ⌈a do out[i] := a[i]+b[i] od; out);
matrix m := (v1, v2, v1+v2);
print ((m[,2:])); # a slice of the 2nd and 3rd columns #

Matrices can be sliced either way, eg:
ref vector row = m[2,]; # define a ref (pointer) to the 2nd row #
ref vector col = m[,2]; # define a ref (pointer) to the 2nd column #

ALGOL 68 supports multiple field structures (struct) and united modes. Reference variables may point to any mode including array slices and structure fields.

For an example of all this, here is the traditional linked list declaration:
mode node = union (real, int, compl, string),
list = struct (node val, ref list next);

Usage example for union case of node:
Algol68 as in the 1968 Final Report
node n := "1234";
real r; int i; compl c; string s
case r,i,c,s::=n in
print(("real:", r)),
print(("int:", i)),
print(("compl:", c)),
print(("string:", s))
out print(("?:", n))
esac
Algol68 as in the 1973 Revised Report
node n := "1234";
 
case n in
(real r): print(("real:", r)),
(int i): print(("int:", i)),
(compl c): print(("compl:", c)),
(string s): print(("string:", s))
out print(("?:", n))
esac


proc: Procedures

Procedure (proc) declarations require type specifications for both the parameters and the result (void if none):
proc max of real = (real a, b) real:
if a > b then a else b fi;
or, using the "brief" form of the conditional statement:
proc max of real = (real a, b) real: (a>b | a | b);
The return value of a proc is the value of the last expression evaluated in the procedure. References to procedures (ref proc) are also permitted. Call-by-reference parameters are provided by specifying references (such as ref real) in the formal argument list. The following example defines a procedure that applies a function (specified as a parameter) to each element of an array:
proc apply = (ref [] real a, proc (real) real f):
 
for i from lwb a to upb a do a[i] := f(a[i]) od
This simplicity of code was unachievable in ALGOL 68's predecessor ALGOL 60
ALGOL 60
ALGOL 60 is a member of the ALGOL family of computer programming languages. It gave rise to many other programming languages, including BCPL, B, Pascal, Simula, C, and many others. ALGOL 58 introduced code blocks and the begin and end pairs for delimiting them...

.

op: Operators

The programmer may define new operators
Operator (programming)
Programming languages typically support a set of operators: operations which differ from the language's functions in calling syntax and/or argument passing mode. Common examples that differ by syntax are mathematical arithmetic operations, e.g...

and both those and the pre-defined ones may be overloaded. The following example defines operator max with both dyadic and monadic versions (scanning across the elements of an array).
prio max = 9;
 
op max = (int a,b) int: ( a>b | a | b );
op max = (real a,b) real: ( a>b | a | b );
op max = (compl a,b) compl: ( abs a > abs b | a | b );
 
op max = ([]real a) real:
(real out := a[lwb a];
for i from lwb a + 1 to upb a do ( a[i]>out | out:=a[i] ) od;
out)

Array, Procedure and Dereference operations

priority Operation +Algol68G
effectively 11 dereferencing, deproceduring(~,~), subscripting[~], rowing[~,] & slicing[~:~] currying(~,)

Monadic operators

priority Algol68 "Worthy characters" +Algol68RR +Algol68C,G +Algol68FR
10 not, up, down, lwb, upb,
-, abs, arg, bin, entier, leng, level, odd, repr, round, shorten
¬, ↑, ↓, ⌊, ⌈ ~ lws, ups, ⎩, ⎧, btb, ctb

Standard dyadic operators with associated priorities

priority Algol68 "Worthy characters" +Algol68RR +Algol68C,G +Algol68FR
9
*, i ×, ⊥
!
8 shl, shr, **, up, down, lwb, upb ↑, ↓, ⌊, ⌈ lws, ups, ⎩, ⎧
7 *, /, %, over, %*, mod, elem ×, ÷, ÷×, ÷*, %×, □ ÷:
6
5 <, lt, <=, le, >=, ge, >, gt ≤, ≥
4 =, eq, /=, ne ~=
3 &, and
2 or
1 minusab, plusab, timesab, divab, overab, modab, plusto,
-:=, +:=, *:=, /:=, %:=, %*:=, +=:
×:=, ÷:=, ÷×:=, ÷*:=, %×:= minus, plus, div, overb, modb, ÷::=, prus

Assignation and identity relations etc

These are technically not operators, rather they are considered "units associated with names"
priority Algol68 "Worthy characters" +Algol68RR +Algol68C +Algol68FR
effectively 0 :=, =:, = , :=:, :/=:, is, isnt, of, at , @ :≠:, : :~=: ct, ::, ctab, ::=, .., is not, →


“:=:” (alternatively “is”) tests if two pointers are equal; “:/=:” (alternatively “isnt”) tests if they are unequal.

Why :=: and :/=: are needed: Consider trying to compare two pointer values, such as the following variables, declared as pointers-to-integer:
ref int ip, jp


Now consider how to decide whether these two are pointing to the same location, or whether one of them is pointing to nil. The following expression
ip = jp


will dereference both pointers down to values of type int, and compare those, since the “=” operator is defined for int, but not ref int. It is not legal to define “=” for operands of type ref int and int at the same time, because then calls become ambiguous, due to the implicit coercions that can be applied: should the operands be left as ref int and that version of the operator called? Or should they be dereferenced further to int and that version used instead? Therefore the following expression can never be made legal:
ip = nil


Hence the need for separate constructs not subject to the normal coercion rules for operands to operators. But there is a gotcha. The following calls:
ip :=: jp
ip :=: nil


while legal, will probably not do what you expect. They will always return false, because they are comparing the actual addresses of the variables ip and jp, rather than what they point to. To achieve the right effect, you have to write
ip :=: ref int(jp)
ip :=: ref int(nil)


Patent application: On 14 May 2003, software patent
Software patent
Software patent does not have a universally accepted definition. One definition suggested by the Foundation for a Free Information Infrastructure is that a software patent is a "patent on any performance of a computer realised by means of a computer program".In 2005, the European Patent Office...

 application No. 20040230959 was filed for the ISNOT operator by employees of Microsoft
Microsoft
Microsoft Corporation is an American public multinational corporation headquartered in Redmond, Washington, USA that develops, manufactures, licenses, and supports a wide range of products and services predominantly related to computing through its various product divisions...

. This patent was granted on 18 November 2004.

Special characters

Most of Algol's "special" characters (×, ÷, ≤, ≥, ≠, ¬, ⊃, ≡, ∨, ∧, →, ↓, ↑, ⌊, ⌈, ⎩, ⎧, ⊥, ⏨, ¢, ○ and □) can be found on the IBM 2741
IBM 2741
The IBM 2741 was a printing computer terminal introduced in 1965.It combined a ruggedized Selectric typewriter mechanism with IBM SLT electronics and an RS-232-C serial interface. It operated at about 14.1 characters per second with a data rate of 134.5 bits/second...

 keyboard with the APL "golf-ball" print head inserted, these became available in the mid 1960s while ALGOL 68 was being drafted. These characters are also part of the unicode
Unicode
Unicode is a computing industry standard for the consistent encoding, representation and handling of text expressed in most of the world's writing systems...

 standard and most of them are available in several popular font
Font
In typography, a font is traditionally defined as a quantity of sorts composing a complete character set of a single size and style of a particular typeface...

s:

transput: Input and output

Transput is the term used to refer to ALGOL 68's input and output facilities. There are pre-defined procedures for unformatted, formatted and binary transput. Files and other transput devices are handled in a consistent and machine-independent manner. The following example prints out some unformatted output to the standard output device:
print ((newpage, "Title", newline, "Value of i is ",
i, "and x[i] is ", x[i], newline))
Note the predefined procedures newpage and newline passed as arguments.

Books, channels and files

The transput is considered to be of books, channels and files:
  • Books are made up of pages, lines and characters, and may be backed up by files.
    • A specific book can be located by name with a call to match.
  • channels correspond to physical devices. eg. card punches and printers.
    • There are three standard channels: stand in channel, stand out channel, stand back channel.
  • A file is a means of communicating between a particular program and a book that has been opened via some channel.
    • The mood of a file may be read, write, char, bin, and opened.
    • transput procedures include: establish, create, open, associate, lock, close, scratch.
    • position enquires: char number, line number, page number.
    • layout routines include:
      • space, backspace, newline, newpage.
      • get good line, get good page, get good book, and proc set=(ref file f, int page,line,char)void:
    • A file has event routines. eg. on logical file end, on physical file end, on page end, on line end, on format end, on value error, on char error.

formatted transput

"Formatted transput" in ALGOL 68's transput has its own syntax and patterns (functions), with formats embedded between two $ characters.
Examples:
printf (($2l"The sum is:"x, g(0)$, m + n)); ¢ prints the same as: ¢
print ((new line, new line, "The sum is:", space, whole (m + n, 0))

par: Parallel processing

ALGOL 68 supports programming of parallel processing. Using the keyword par, a collateral clause is converted to a parallel clause, where the synchronisation of actions is controlled using semaphore
Semaphore (programming)
In computer science, a semaphore is a variable or abstract data type that provides a simple but useful abstraction for controlling access by multiple processes to a common resource in a parallel programming environment....

s. In A68G the parallel actions are mapped to threads when available on the hosting operating system
Operating system
An operating system is a set of programs that manage computer hardware resources and provide common services for application software. The operating system is the most important type of system software in a computer system...

. In A68S a different paradigm of parallel processing was implemented (see below).
int initial foot width = 5;
mode foot = struct(
string name,
sema width,
bits toe ¢ packed vector of BOOL ¢
);
 
foot left foot:= foot("Left", level initial foot width, 2r11111),
right foot:= foot("Right", level initial foot width, 2r11111);
 
¢ 10 round clip in a 1968 Colt Python .357 Magnum ¢
sema rounds = level 10;
 
¢ the Magnum needs more barrels to take full advantage of parallelism ¢
sema acquire target = level 1;

prio ∧:= = 1;
op ∧:= = (ref bits lhs, bits rhs)ref bits: lhs := lhs ∧ rhs;
 
proc shoot = (ref foot foot)void: (
↓acquire target;
↓rounds;
print("BANG! ");
↓width → foot;
toe → foot ∧:= ¬(bin 1 shl level width → foot);
printf(($g": Ouch!! - "5(g)l$, name → foot, []bool(toe → foot)[bits width - initial foot width + 1:]));
↑acquire target
);
 
¢ do shooting in parallel to cater for someone hoping to stand on just one foot ¢
par (
for toe to initial foot width do
shoot(left foot)
od, ¢ <= a comma is required ¢
for toe to initial foot width do
shoot(right foot)
od
)

Code sample

This sample program implements the Sieve of Eratosthenes
Sieve of Eratosthenes
In mathematics, the sieve of Eratosthenes , one of a number of prime number sieves, is a simple, ancient algorithm for finding all prime numbers up to a specified integer....

 to find all the prime number
Prime number
A prime number is a natural number greater than 1 that has no positive divisors other than 1 and itself. A natural number greater than 1 that is not a prime number is called a composite number. For example 5 is prime, as only 1 and 5 divide it, whereas 6 is composite, since it has the divisors 2...

s that are less than 100. nil is the ALGOL 68 analogue of the null pointer in other languages. The notation x of y accesses a member x of a struct y.

begin # Algol-68 prime number sieve, functional style #
 
proc error = (string s) void:
(print(( newline, " error: ", s, newline)); goto stop);
proc one to = (int n) list:
(proc f = (int m,n) list: (m>n | nil | cons(m, f(m+1,n))); f(1,n));
 
mode list = ref node;
mode node = struct (int h, list t);
proc cons = (int n, list l) list: heap node := (n,l);
proc hd = (list l) int: ( l is nil | error("hd nil"); skip | h of l );
proc tl = (list l) list: ( l is nil | error("tl nil"); skip | t of l );
proc show = (list l) void: ( l isnt nil | print((" ",whole(hd(l),0))); show(tl(l)));
 
proc filter = (proc (int) bool p, list l) list:
if l is nil then nil
elif p(hd(l)) then cons(hd(l), filter(p,tl(l)))
else filter(p, tl(l))
fi;
 
proc sieve = (list l) list:
if l is nil then nil
else
proc not multiple = (int n) bool: n mod hd(l) ≠ 0;
cons(hd(l), sieve( filter( not multiple, tl(l) )))
fi;
 
proc primes = (int n) list: sieve( tl( one to(n) ));
 
show( primes(100) )
end

Operating Systems written in ALGOL 68

  • Cambridge CAP computer - All procedures constituting the operating system were written in ALGOL 68C
    ALGOL 68C
    The ALGOL68C computer programming language compiler was developed for the CHAOS OS for the CAP capability computer at Cambridge University in 1971 by Stephen Bourne and Michael Guy as a dialect of ALGOL 68. Other early contributors were Andrew D. Birrell and Ian Walker.The initial compiler was...

    , although a number of other closely associated protected procedures - such as a paginator - are written in BCPL
    BCPL
    BCPL is a procedural, imperative, and structured computer programming language designed by Martin Richards of the University of Cambridge in 1966.- Design :...

    . http://research.microsoft.com/pubs/72418/cap.pdf
  • Eldon 3
    Eldon
    -Places:* Eldon, County Durham, England* Eldon Lane, County Durham, England* Old Eldon, County Durham, England* Eldon Hill, Derbyshire, England* Eldon, Iowa, USA* Eldon, Missouri, USA* Eldon Township, Benson County, North Dakota, USA* Eldon, Oklahoma, USA...

     - Developed at Leeds University for the ICL 1900
    ICT 1900 series
    ICT 1900 was the name given to a series of mainframe computers released by International Computers and Tabulators and later International Computers Limited during the 1960s and '70s...

     was written in ALGOL 68R
    ALGOL 68R
    ALGOL 68-R was the first implementation of the Algorithmic language ALGOL 68.In December 1968 the report on the Algorithmic language ALGOL 68 was published. On 20–24 July 1970 a working conference was arranged by the IFIP to discuss the problems of implementation of the language, a small team from...

    .
  • Flex machine
    Flex machine
    In computing, there have been multiple systems named FLEX.-Alan Kay's FLEX system:Alan Kay developed his Flex system in the late 1960s while exploring ideas that would later evolve into the Smalltalk programming language.-RSRE FLEX Computer System:...

     - The hardware was custom and microprogrammable, with an operating system, (modular) compiler, editor, garbage collector and filing system all written in ALGOL 68RS
    ALGOL 68RS
    An extension of ALGOL 68 supporting function closures by the Royal Signals and Radar Establishment . It has been ported to Multics and VAX/VMS....

    . The command shell Curt http://www.vitanuova.com/dist/doc/rsre-3522-curt.pdf was designed to access typed data similar to Algol-68 modes.
  • VME - S3 was the implementation language of the operating system
    Operating system
    An operating system is a set of programs that manage computer hardware resources and provide common services for application software. The operating system is the most important type of system software in a computer system...

     VME. S3 was based on ALGOL 68 but with data types and operators aligned to those offered by the ICL 2900 Series
    ICL 2900 Series
    The ICL 2900 Series was a range of mainframe computer systems announced by the UK manufacturer ICL on 9 October 1974. The company had started development, under the name "New Range" immediately on its formation in 1968...

    .

Note: The Soviet Era computers Эльбрус-1 (Elbrus-1)
Elbrus (computer)
The Elbrus is a line of Soviet and Russian computer systems developed by Lebedev Institute of Precision Mechanics and Computer Engineering.In 1992 a spin-off company Moscow Center of SPARC Technologies was created and continued development....

 and Эльбрус-2 were created using high-level language uЭль-76 (AL-76), rather than the traditional assembly. uЭль-76 resembles Algol-68, The main difference is the dynamic binding types in uЭль-76 supported at the hardware level. uЭль-76 is used for application, job control, system programming http://www.ixbt.com/cpu/e2k-spec.html.

Applications

Both ALGOL 68C
ALGOL 68C
The ALGOL68C computer programming language compiler was developed for the CHAOS OS for the CAP capability computer at Cambridge University in 1971 by Stephen Bourne and Michael Guy as a dialect of ALGOL 68. Other early contributors were Andrew D. Birrell and Ian Walker.The initial compiler was...

 and ALGOL 68R
ALGOL 68R
ALGOL 68-R was the first implementation of the Algorithmic language ALGOL 68.In December 1968 the report on the Algorithmic language ALGOL 68 was published. On 20–24 July 1970 a working conference was arranged by the IFIP to discuss the problems of implementation of the language, a small team from...

 are written in ALGOL 68, effectively making ALGOL 68 an application of itself. Other applications include:
  • ELLA
    ELLA (programming language)
    ELLA is a Hardware description language and support toolset. Developed by the Royal Signals and Radar Establishment during the 1980s and 90s.Includes tools to perform:* design transformation* symbolic simulations* formal verification...

     - a hardware description language and support toolset. Developed by the Royal Signals and Radar Establishment
    Royal Signals and Radar Establishment
    The Royal Signals and Radar Establishment was a scientific research establishment within the Ministry of Defence of the United Kingdom, located primarily at Malvern in Worcestershire. It was formed in 1976 in an amalgamation of earlier research establishments including the Royal Radar Establishment...

     during the 1980s and 90s.

Libraries and APIs

  • NAG Numerical Libraries
    NAG Numerical Libraries
    NAG Numerical Libraries is a software product sold by The Numerical Algorithms Group Ltd . The product is a software library of numerical analysis routines. It comprises a collection of 1500 mathematical and statistical algorithms. Areas covered include linear algebra, optimization, quadrature,...

     - a software library of numerical analysis
    Numerical analysis
    Numerical analysis is the study of algorithms that use numerical approximation for the problems of mathematical analysis ....

     routines. Supplied in ALGOL 68 during the 1980s.
  • TORRIXhttp://hopl.murdoch.edu.au/showlanguage.prx?exp=3911&language=TORRIX - a programming system for operations on vectors and matrices over arbitrary fields and of variable size by S.G. van der Meulen and M. Veldhorst.

Program representation

A feature of ALGOL 68, inherited from ALGOL
ALGOL
ALGOL is a family of imperative computer programming languages originally developed in the mid 1950s which greatly influenced many other languages and became the de facto way algorithms were described in textbooks and academic works for almost the next 30 years...

 tradition, is its different representations. There is a representation language used to describe algorithms in printed work, a strict language (rigorously defined in the Report) and an official reference language intended to be used in actual compiler input. In the examples above you will observe underlined words. This is the formal representation of the language. ALGOL 68's reserved words are effectively in a different namespace
Namespace (computer science)
A namespace is an abstract container or environment created to hold a logical grouping of unique identifiers or symbols . An identifier defined in a namespace is associated only with that namespace. The same identifier can be independently defined in multiple namespaces...

 from identifiers, and spaces are allowed in identifiers, so the fragment:
int a real int = 3 ;
is legal. The programmer who actually writes the code does not have the option of underlining the code. Depending on hardware and cultural issues, different methods to denote these identifiers, have been devised, called stropping
Stropping
When applied to computer languages, stropping refers to the method used to mark letter sequences as having a special property such as being a keyword or certain type of variable or storage location....

 regime
s. So all or some of the following may be possible programming representations:
'INT' A REAL INT = 3;
.INT A REAL INT = 3; # the POINT stropping style #
INT a real int = 3;# the UPPER stropping style #
int a_real_int = 3;# the RES stropping style, there are 61 accepted reserved words #
All implementations must recognise at least POINT, UPPER and RES inside PRAGMAT sections.

The following characters were recommended for portability, and termed "worthy characters" in the Report on the Standard Hardware Representation of Algol 68:Worthy Characters: ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789 "#$%'*+,-./:;<=>@[ ]_|
This reflected a problem in the 1960s where some hardware didn't support lower-case, nor some other non ASCII
ASCII
The American Standard Code for Information Interchange is a character-encoding scheme based on the ordering of the English alphabet. ASCII codes represent text in computers, communications equipment, and other devices that use text...

 characters, indeed in the 1973 report it was written: "Four worthy characters -- "|", "_", "[", and "]" -- are often coded differently, even at installations which nominally use the same character set."
  • Base characters: "Worthy characters" are a subset of "base characters".

Example of different program representations

Algol68 as typically published
¢ bold/underline typeface ¢
mode xint = int;
xint sum sq:=0;
for i while
sum sq≠70×70
do
sum sq+:=i↑2
od
Quote stropping (like wikitext)
'pr' quote 'pr'
'mode' 'xint' = 'int';
'xint' sum sq:=0;
'for' i 'while'
sum sq≠70×70
'do'
sum sq+:=i↑2
'od'
For a 7-bit character code compiler
.PR UPPER .PR
MODE XINT = INT;
XINT sum sq:=0;
FOR i WHILE
sum sq/=70*70
DO
sum sq+:=i**2
OD
For a 6-bit character code compiler
.PR POINT .PR
.MODE .XINT = .INT;
.XINT SUM SQ:=0;
.FOR I .WHILE
SUM SQ .NE 70*70
.DO
SUM SQ .PLUSAB I .UP 2
.OD
Using res stropping of reserved word
.PR RES .PR
mode .xint = int;
.xint sum sq:=0;
for i while
sum sq≠70×70
do
sum sq+:=i↑2
od

ALGOL 68 allows for every natural language to define its own set of keywords Algol-68. As a result, programmers are able to write programs using keywords from their native language. Below is an example of a simple procedure that calculates "the day following", the code is in two languages: English and German.

# Next day date - English variant #
mode date = struct(int day, string month, int year);
proc the day following = (date x) date:
if day of x < length of month (month of x, year of x)
then (day of x + 1, month of x, year of x)
elif month of x = "December"
then (1, "January", year of x + 1)
else (1, successor of month (month of x), year of x)
fi;


# Nachfolgetag - Deutsche Variante #
menge datum = tupel(ganz tag, wort monat, ganz jahr);
funktion naechster tag nach = (datum x) datum:
wenn tag von x < monatslaenge(monat von x, jahr von x)
dann (tag von x + 1, monat von x, jahr von x)
wennaber monat von x = "Dezember"
dann (1, "Januar", jahr von x + 1)
ansonsten (1, nachfolgemonat(monat von x), jahr von x)
endewenn;

Russian/Soviet example:
In English Algol68's reverent case statement reads case ~ in ~ out ~ esac, in Cyrillic this reads выб ~ в ~ либо ~ быв.

Some Vanitas

For its technical intricacies, ALGOL 68 needs a cornucopia of methods to deny the existence of something:

skip, "~" or "?"C - an undefined value always syntactically valid,
empty - the only value admissible to void, needed for selecting void in a union,
void - syntactically like a mode, but not one,
nil or "○" - a name not denoting anything, of an unspecified reference mode,
or specifically [1:0]int - a vacuum is an empty array (here specifically of mode []int).
undefined - a standards reports procedure raising an exception in the runtime system.
ℵ - Used in the standards report to inhibit introspection
Introspection
Introspection is the self-observation and reporting of conscious inner thoughts, desires and sensations. It is a conscious and purposive process relying on thinking, reasoning, and examining one's own thoughts, feelings, and, in more spiritual cases, one's soul...

 of certain types. eg sema

c.f. below for other examples of ℵ.

The term nil is var always evaluates to true for any variable (but see above for correct use of is :/=:), whereas it is not known to which value a comparison x < skip evaluates for any integer x.

ALGOL 68 leaves intentionally undefined what happens in case of integer overflow, the integer bit representation, and the degree of numerical accuracy for floating point. In contrast, the language Java
Java (programming language)
Java is a programming language originally developed by James Gosling at Sun Microsystems and released in 1995 as a core component of Sun Microsystems' Java platform. The language derives much of its syntax from C and C++ but has a simpler object model and fewer low-level facilities...

 has been criticized for over-specifying the latter.

Both official reports included some advanced features that were not part of the standard language. This were indicated with an ℵ and considered effectively private. Examples include "≮" and "≯" for templates, the outtype/intype for crude duck typing
Duck typing
In computer programming with object-oriented programming languages, duck typing is a style of dynamic typing in which an object's current set of methods and properties determines the valid semantics, rather than its inheritance from a particular class or implementation of a specific interface...

, and the straightout and straightin operators for "straightening" nested arrays and structures.

Extract from the 1973 report:
§10.3.2.2. Transput modes
a) modesimplout = union (≮ℒ int≯, ≮ℒ real≯, ≮ℒ compl≯, bool, ≮ℒ bits≯,
char, [ ] char);
b) modeouttype = ¢ an actual - declarer specifying a mode united
from a sufficient set of modes none of which is 'void' or contains 'flexible',
'reference to', 'procedure' or 'union of' ¢;
c) modesimplin = union (≮ref ℒ int≯, ≮ref ℒ real≯, ≮refcompl≯, ref bool,
ref ℒ bits≯, ref char, ref [ ] char, ref string);
d) modeintype = ¢ ... ¢;

§10.3.2.3. Straightening
a) opstraightout = (outtype x) [ ] simplout: ¢ the result of "straightening" 'x' ¢;
b) opstraightin = (intype x) [ ] simplin: ¢ the result of straightening 'x' ¢;

Comparisons with other languages

  • 1973 - Comparative Notes on Algol 68 and PL/I - S. H. Valentine - February 1973
  • 1973 - B. R. Alexander and G. E. Hedrick. A Comparison of PL/1 and ALGOL 68. International Symposium on Computers and Chinese Input/Output Systems. pp. 359–368.
  • 1976 - Evaluation of ALGOL 68, Jovial J3B, Pascal
    Pascal (programming language)
    Pascal is an influential imperative and procedural programming language, designed in 1968/9 and published in 1970 by Niklaus Wirth as a small and efficient language intended to encourage good programming practices using structured programming and data structuring.A derivative known as Object Pascal...

    , SIMULA
    Simula
    Simula is a name for two programming languages, Simula I and Simula 67, developed in the 1960s at the Norwegian Computing Center in Oslo, by Ole-Johan Dahl and Kristen Nygaard...

     67, and TACPOL Versus TINMAN - Requirements for a Common High Order Programming Language.
  • 1976 - A Language Comparison - A Comparison of the Properties of the Programming Languages ALGOL 68, CAMAC-IML, Coral 66, PAS 1, PEARL, PL/1, PROCOL, RTL/2
    RTL/2
    RTL/2 was a high-level programming language developed at Imperial Chemical Industries Ltd by J.G.P. Barnes. It was originally used internally within ICI but was distributed by SPL International in 1974...

     in Relation to Real Time Programming - R Roessler; K Schenk - Oct 1976
  • 1977 - Report to the High Order-Language Working Group (HOLWG) - Executive Summary - LANGUAGE EVALUATION COORDINATING COMMITTEE - Evaluation of PL/I, Pascal, ALGOL 68, HAL/S, PEARL
    PEARL programming language
    PEARL, or Process and Experiment Automation Realtime Language, is a computer programming language designed for multitasking and real-time programming. Being a high-level language, it is fairly cross-platform. Since 1977, the language has been going under several standardization steps by the...

    , SPL/I, PDL/2, LTR, CS-4, LIS, Euclid
    Euclid programming language
    Euclid is an imperative programming language for writing verifiable programs. It was designed by Butler Lampson and associates at the Xerox PARC lab in the mid 1970s. The implementation was led by Ric Holt at the University of Toronto and James Cordy was the principal programmer for the first...

    , ECL
    ECL programming language
    The ECL programming language and system were an extensible high-level programming language and development environment developed at Harvard University in the 1970s. The name 'ECL' stood for 'Extensible Computer Language' or 'EClectic Language'...

    , Moral, RTL/2
    RTL/2
    RTL/2 was a high-level programming language developed at Imperial Chemical Industries Ltd by J.G.P. Barnes. It was originally used internally within ICI but was distributed by SPL International in 1974...

    , FORTRAN, COBOL, ALGOL 60, TACPOL
    TACPOL programming language
    TACPOL is a block structured programming language developed by the United States Army for the TACFIRE Tactical Fire Direction command and control application. TACPOL is similar to PL/I.-Data types:...

    , CMS-2
    CMS-2 programming language
    CMS-2 is an embedded systems programming language used by the United States Navy. It was developed by Rand Corporation in the early 1970s and stands for "Compiler Monitor System". The name "CMS-2" is followed in literature by a letter designating the type of target system...

    , SIMULA 67
    Simula
    Simula is a name for two programming languages, Simula I and Simula 67, developed in the 1960s at the Norwegian Computing Center in Oslo, by Ole-Johan Dahl and Kristen Nygaard...

    , Jovial J3B, Jovial J73 & Coral 66.
  • 1977 - A comparison of PASCAL and ALGOL 68http://dare.ubvu.vu.nl/bitstream/1871/2609/1/11054.pdf - Andrew S. Tanenbaum
    Andrew S. Tanenbaum
    Andrew Stuart "Andy" Tanenbaum is a professor of computer science at the Vrije Universiteit, Amsterdam in the Netherlands. He is best known as the author of MINIX, a free Unix-like operating system for teaching purposes, and for his computer science textbooks, regarded as standard texts in the...

     - June 1977.
  • 1980 - A Critical Comparison of Several Programming - Algol 60, FORTRAN, Pascal and Algol 68.
  • 1993 - Five Little Languages and How They Grew - BLISS
    BLISS
    BLISS is a system programming language developed at Carnegie Mellon University by W. A. Wulf, D. B. Russell, and A. N. Habermann around 1970. It was perhaps the best known systems programming language right up until C made its debut a few years later. Since then, C took off and BLISS faded into...

    , Pascal, Algol 68
    ALGOL 68
    ALGOL 68 isan imperative computerprogramming language that was conceived as a successor to theALGOL 60 programming language, designed with the goal of a...

    , BCPL
    BCPL
    BCPL is a procedural, imperative, and structured computer programming language designed by Martin Richards of the University of Cambridge in 1966.- Design :...

     & C
    C (programming language)
    C is a general-purpose computer programming language developed between 1969 and 1973 by Dennis Ritchie at the Bell Telephone Laboratories for use with the Unix operating system....

     - Dennis M. Ritchie - April 1993.
  • 1999 - On Orthogonality: Algol68, Pascal and C
  • 2000 - A Comparison of Arrays in ALGOL 68 and BLISS
    BLISS
    BLISS is a system programming language developed at Carnegie Mellon University by W. A. Wulf, D. B. Russell, and A. N. Habermann around 1970. It was perhaps the best known systems programming language right up until C made its debut a few years later. Since then, C took off and BLISS faded into...

     - University of Virginia
    University of Virginia
    The University of Virginia is a public research university located in Charlottesville, Virginia, United States, founded by Thomas Jefferson...

     - Michael Walker - Spring 2000
  • 2009 - On Go - oh, go on - How well will Google's Go stand up against Brand X programming language? - David Given - November 2009
  • Comparison of ALGOL 68 and C++
    Comparison of ALGOL 68 and C++
    The nearest living sibling to ALGOL 68 may be C++, making this a good comparison candidate:C++ doesn't have:* PROC - first class nested functions ,...

    .

Variants

Except where noted (with a superscript), the language described above is that of the "Revised Report(RR)".

The language of the unrevised report

The original language(FR) differs in syntax of the mode cast, and it had the feature of proceduring, i.e. coercing the value of a term into a procedure which evaluates the term. Proceduring would be intended to make evaluations lazy. The most useful application could have been the short-circuited evaluation of boolean operators. In
op andf = (bool a,proc bool b)bool:(a | b | false);
op orf = (bool a,proc bool b)bool:(a | true | b);
b is only evaluated if a is true.
As defined in ALGOL 68, it did not work as expected, for example in the code:

if false andf co proc bool: co ( print ("Should not be executed"); true)
then ...

against the programmers naïve expectations the print would be executed as it is only the value of the elaborated enclosed-clause after andf that was procedured. Textual insertion of the commented-out proc bool: makes it work.

Some implementations emulate the expected behaviour for this special case by extension of the language.

Before revision, the programmer could decide to have the arguments of a procedure evaluated serially instead of collaterally by using semicolons instead of commas (gommas).

For example in:

proc test = (real a; real b) :...
...
test (x plus 1, x);

The first argument to test is guaranteed to be evaluated before the second, but in the usual:

proc test = (real a, b) :...
...
test (x plus 1, x);

then the compiler could evaluate the arguments in whatever order it felt like.

Extension proposals from IFIP WG 2.1

After the revision of the report, some extensions to the language have been proposed to widen the applicability:
  • partial parametrisation (aka Currying): creation of functions (with fewer parameters) by specification of some, but not all parameters for a call, e.g. a function logarithm of two parameters, base and argument, could be specialised to natural, binary or decadic log,
  • module extension: for support of external linkage, two mechanisms were proposed, bottom-up definition modules, a more powerful version of the facilities from ALGOL 68R
    ALGOL 68R
    ALGOL 68-R was the first implementation of the Algorithmic language ALGOL 68.In December 1968 the report on the Algorithmic language ALGOL 68 was published. On 20–24 July 1970 a working conference was arranged by the IFIP to discuss the problems of implementation of the language, a small team from...

     and top-down holes, similar to the ENVIRON and USING clauses from ALGOL 68C
    ALGOL 68C
    The ALGOL68C computer programming language compiler was developed for the CHAOS OS for the CAP capability computer at Cambridge University in 1971 by Stephen Bourne and Michael Guy as a dialect of ALGOL 68. Other early contributors were Andrew D. Birrell and Ian Walker.The initial compiler was...

  • mode parameters: for implementation of limited parametrical polymorphism (most operations on data structures like lists, trees or other data containers can be specified without touching the pay load).

So far, only partial parametrisation has been implemented, in ALGOL68G.

True ALGOL 68s specification and implementation timeline

Name Year Purpose State Description Target CPU Licencing Implementation Language
Generalized ALGOL 1962 Scientific NL ALGOL for generalised grammars
ALGOL Y
ALGOL Y
ALGOL Y was the name given to a speculated successor for the ALGOL 60 programming language that incorporated some radical features that were rejected for ALGOL 68 and ALGOL X...

Y
1966 Draft proposal Intl First version of Algol 68 Specification ACM
Association for Computing Machinery
The Association for Computing Machinery is a learned society for computing. It was founded in 1947 as the world's first scientific and educational computing society. Its membership is more than 92,000 as of 2009...

ALGOL 68DR 1968 Draft proposal Intl IFIP WG 2.1 Draft Report Specification - March ACM
ALGOL 68FR 1968 Standard Intl IFIP WG 2.1 Final Report Specification - August ACM
ALGOL 68R
ALGOL 68R
ALGOL 68-R was the first implementation of the Algorithmic language ALGOL 68.In December 1968 the report on the Algorithmic language ALGOL 68 was published. On 20–24 July 1970 a working conference was arranged by the IFIP to discuss the problems of implementation of the language, a small team from...

R
1970 Military UK ICL 1900
ICT 1900 series
ICT 1900 was the name given to a series of mainframe computers released by International Computers and Tabulators and later International Computers Limited during the 1960s and '70s...

 
ALGOL 60
EPOS ALGOLE 1971 Scientific
ALGOL 68RS
ALGOL 68RS
An extension of ALGOL 68 supporting function closures by the Royal Signals and Radar Establishment . It has been ported to Multics and VAX/VMS....

RS
1972 Military UK Portable compiler system ICL 2900/Series 39, Multics, VMS & C generator (1993) Crown Copyright
Crown copyright
Crown copyright is a form of copyright claim used by the governments of a number of Commonwealth realms. It provides special copyright rules for the Crown .- Australia :...

 
ALGOL 68RS
Algol 68 with areas 1972 Experimental & other UK Addition of areas to Algol 68
Mini ALGOL 68 1973 Research NL "An interpreter for simple Algol 68 Programs" Portable interpreter Mathematisch Centrum  ALGOL 60
ALGOL 60
ALGOL 60 is a member of the ALGOL family of computer programming languages. It gave rise to many other programming languages, including BCPL, B, Pascal, Simula, C, and many others. ALGOL 58 introduced code blocks and the begin and end pairs for delimiting them...

OREGANO
Oregano
Oregano – scientifically named Origanum vulgare by Carolus Linnaeus – is a common species of Origanum, a genus of the mint family . It is native to warm-temperate western and southwestern Eurasia and the Mediterranean region.Oregano is a perennial herb, growing from 20–80 cm tall,...

1973 Research US "The importance of implementation models." UCLA
ALGOL 68C
ALGOL 68C
The ALGOL68C computer programming language compiler was developed for the CHAOS OS for the CAP capability computer at Cambridge University in 1971 by Stephen Bourne and Michael Guy as a dialect of ALGOL 68. Other early contributors were Andrew D. Birrell and Ian Walker.The initial compiler was...

C
1975 Scientific UK Cambridge Algol 68 ICL, IBM 360, PDP 10 & Unix, Telefunken
Telefunken
Telefunken is a German radio and television apparatus company, founded in Berlin in 1903, as a joint venture of Siemens & Halske and the Allgemeine Elektricitäts-Gesellschaft...

, Tesla & Z80(1980)http://www.80bus.co.uk/publications/magazines/LSG3.pdf
Cambridge ALGOL 68C
ALGOL 68 RevisedRR 1975 Standard Intl IFIP WG 2.1 Revised Report Specification ACM
Algol HH 1975 Experimental & other UK Proposed extensions to the mode system of Algol 68 Specification ALGOL W
ALGOL W
ALGOL W is a programming language. It was based on a proposal for ALGOL X by Niklaus Wirth and C. A. R. Hoare as a successor to ALGOL 60 in IFIP Working Group 2.1. When the committee decided that the proposal was not a sufficient advance over ALGOL 60, the proposal was published as A contribution...

Odra
Odra (computer)
Odra was a line of computers manufactured in Wrocław, Poland.The production started in 1959–1960. Models 1001, 1002, 1003, 1013, 1103, 1204 were of original Polish construction. Models 1304 and 1305 were functional counterparts of ICL 1905 and 1906 due to software agreement...

 Algol 68
1976 practical uses USSR/Poland Odra 1204/IL Soviet
Copyright law of the Soviet Union
The Copyright law of the Soviet Union went through several major revisions during its existence. The first Socialist copyright law was passed in 1925. Three years later, it was superseded by a second version that remained in force for more than three decades, until it was replaced in...

 
ALGOL 60
ALGOL 60
ALGOL 60 is a member of the ALGOL family of computer programming languages. It gave rise to many other programming languages, including BCPL, B, Pascal, Simula, C, and many others. ALGOL 58 introduced code blocks and the begin and end pairs for delimiting them...

Oklahoma ALGOL 68 1976 programming instruction USA Oklahoma State University implementation http://htportal.acm.org/ft_gateway.cfm?id=803425&type=pdf IBM 1130
IBM 1130
The IBM 1130 Computing System was introduced in 1965. It was IBM's least-expensive computer to date, and was aimed at price-sensitive, computing-intensive technical markets like education and engineering. It succeeded the IBM 1620 in that market segment. The IBM 1800 was a process control variant...

 and System/370
System/370
The IBM System/370 was a model range of IBM mainframes announced on June 30, 1970 as the successors to the System/360 family. The series maintained backward compatibility with the S/360, allowing an easy migration path for customers; this, plus improved performance, were the dominant themes of the...

/158
Unknown ANSI Fortran 66
Berlin ALGOL 68 1977 Research DE "The Berlin ALGOL 68 implementation" & http://www.springerlink.com/content/7v453r50u0782903/ An Abstract ALGOL 68 Machine - machine independent Compiler Technical University of Berlin
Technical University of Berlin
The Technische Universität Berlin is a research university located in Berlin, Germany. Translating the name into English is discouraged by the university, however paraphrasing as Berlin Institute of Technology is recommended by the university if necessary .The TU Berlin was founded...

 
CDL 2
Compiler Description Language
Compiler Description Language, or CDL, is a Computer language based on affix grammars. It is very similar to Backus–Naur form notation. It was designed for the development of compilers. It is very limited in its capabilities and control flow; and intentionally so. The benefits of these limitations...

FLACC
FLACC
FLACC is an implementation of the ALGOL 68 programming language.Chris Thomson and Colin Broughton founded Chion Corporation which developed and marketed FLACC . This compiler and run-time system conformed exactly to the Revised Report, ran on IBM 370 and compatible mainframes, and included...

F
1977 Multi-purpose CA Revised Report complete implementation with debug features System/370 lease, Chion Corporation Assembler
ALGOL 68-RTRT 1979 Scientific UK Parallel ALGOL 68-R
RS Algolrs 1979 Scientific UK
ALGOL 68+ 1980 Scientific NL Proposed superlanguage of ALGOL 68 http://hopl.murdoch.edu.au/showlanguage2.prx?exp=4351
M-220 ALGOL 68 USSR M-220 Soviet
Copyright law of the Soviet Union
The Copyright law of the Soviet Union went through several major revisions during its existence. The first Socialist copyright law was passed in 1925. Three years later, it was superseded by a second version that remained in force for more than three decades, until it was replaced in...

 
EPSILON
EPSILON (programming language)
A macro language with high level features including strings and lists, developed by A.P. Ershov at Novosibirsk in 1967. EPSILON was used to implement ALGOL 68 on the M-220 computer.- See also :...

ALGOL 68 LGUL 1980 Telecommunications USSR Full Language + Modules IBM, DEC, CAMCOH, PS 1001 & PC Soviet
Copyright law of the Soviet Union
The Copyright law of the Soviet Union went through several major revisions during its existence. The first Socialist copyright law was passed in 1925. Three years later, it was superseded by a second version that remained in force for more than three decades, until it was replaced in...

Interactive ALGOL 68
Interactive ALGOL 68
The Interactive ALGOL 68 compiler for ALGOL 68 was made available by Peter Craven of Algol Applications from 1984. Then in 1994 from OCCL until 2004.-Platforms:* Inmos Transputer family...

I
1983 UK Incremental compilation PC Noncommercial shareware
Shareware
The term shareware is a proprietary software that is provided to users without payment on a trial basis and is often limited by any combination of functionality, availability, or convenience. Shareware is often offered as a download from an Internet website or as a compact disc included with a...

ALGOL 68S
ALGOL 68S
ALGOL 68S was designed as a subset of ALGOL 68 in order to permit single-pass compilation. It was mostly for numerical computation.-Implementations:...

S
1985 Scientific Intl Sun version of ALGOL 68 Sun-3
Sun-3
Sun-3 was the name given to a series of UNIX computer workstations and servers produced by Sun Microsystems, launched on September 9th, 1985. The Sun-3 series were VMEbus-based systems similar to some of the earlier Sun-2 series, but using the Motorola 68020 microprocessor, in combination with the...

, Sun SPARC
SPARC
SPARC is a RISC instruction set architecture developed by Sun Microsystems and introduced in mid-1987....

 (under SunOS
SunOS
SunOS is a version of the Unix operating system developed by Sun Microsystems for their workstation and server computer systems. The SunOS name is usually only used to refer to versions 1.0 to 4.1.4 of SunOS...

 4.1 & Solaris 2), Atari
Atari
Atari is a corporate and brand name owned by several entities since its inception in 1972. It is currently owned by Atari Interactive, a wholly owned subsidiary of the French publisher Atari, SA . The original Atari, Inc. was founded in 1972 by Nolan Bushnell and Ted Dabney. It was a pioneer in...

 ST (under GEMDOS
Atari ST
The Atari ST is a home/personal computer that was released by Atari Corporation in 1985 and commercially available from that summer into the early 1990s. The "ST" officially stands for "Sixteen/Thirty-two", which referred to the Motorola 68000's 16-bit external bus and 32-bit internals...

), Acorn Archimedes
Acorn Archimedes
The Acorn Archimedes was Acorn Computers Ltd's first general purpose home computer to be based on their own ARM architecture.Using a RISC design with a 32-bit CPU, at its launch in June 1987, the Archimedes was stated as running at 4 MIPS, with a claim of 18 MIPS during tests.The name is commonly...

 (under RISC OS
RISC OS
RISC OS is a computer operating system originally developed by Acorn Computers Ltd in Cambridge, England for their range of desktop computers, based on their own ARM architecture. First released in 1987, under the name Arthur, the subsequent iteration was renamed as in 1988...

), VAX-11
VAX-11
The VAX-11 was a family of minicomputers developed and manufactured by Digital Equipment Corporation using processors implementing the VAX instruction set architecture . The VAX-11/780 was the first VAX computer.- VAX-11/780 :...

 under Ultrix-32 
Algol68toC http://sourceforge.net/projects/algol68/files/(ctrans) 1985 Electronics UK ctrans from ELLA
ELLA (programming language)
ELLA is a Hardware description language and support toolset. Developed by the Royal Signals and Radar Establishment during the 1980s and 90s.Includes tools to perform:* design transformation* symbolic simulations* formal verification...

 ALGOL 68RS
ALGOL 68RS
An extension of ALGOL 68 supporting function closures by the Royal Signals and Radar Establishment . It has been ported to Multics and VAX/VMS....

 
Portable C generator  Open Source
Open source
The term open source describes practices in production and development that promote access to the end product's source materials. Some consider open source a philosophy, others consider it a pragmatic methodology...

d & Public Domain
Public domain
Works are in the public domain if the intellectual property rights have expired, if the intellectual property rights are forfeited, or if they are not covered by intellectual property rights at all...

ed 1995
ALGOL 68RS
MK2 Interactive ALGOL 68
Interactive ALGOL 68
The Interactive ALGOL 68 compiler for ALGOL 68 was made available by Peter Craven of Algol Applications from 1984. Then in 1994 from OCCL until 2004.-Platforms:* Inmos Transputer family...

1992 UK Incremental compilation PC Noncommercial shareware http://www.nunan.fsnet.co.uk/algol68/a68mk2.zip
ALGOL 68G
ALGOL 68G
ALGOL68G or Algol 68 Genie is a recent ALGOL 68 compiler-interpreter. ALGOL68G is a nearly full implementation of ALGOL 68 as defined by the Revised Report and also implements partial parametrisation, which is an extension of ALGOL 68. After successful parsing of an entire source program, the...

G
2001 Full Language NL Includes standard collateral clause Portable interpreter GPL
GNU General Public License
The GNU General Public License is the most widely used free software license, originally written by Richard Stallman for the GNU Project....

 
C
C (programming language)
C is a general-purpose computer programming language developed between 1969 and 1973 by Dennis Ritchie at the Bell Telephone Laboratories for use with the Unix operating system....

ALGOL 68G
ALGOL 68G
ALGOL68G or Algol 68 Genie is a recent ALGOL 68 compiler-interpreter. ALGOL68G is a nearly full implementation of ALGOL 68 as defined by the Revised Report and also implements partial parametrisation, which is an extension of ALGOL 68. After successful parsing of an entire source program, the...

 Version 2.0.0
2010 Full Language NL Portable interpreter; optional compilation of selected units GPL
GNU General Public License
The GNU General Public License is the most widely used free software license, originally written by Richard Stallman for the GNU Project....

 
C
C (programming language)
C is a general-purpose computer programming language developed between 1969 and 1973 by Dennis Ritchie at the Bell Telephone Laboratories for use with the Unix operating system....



The S3 programming language
S3 (programming language)
S3 is a structured, imperative high-level computer programming language. It was developed by the UK company International Computers Limited for its 2900 Series mainframes. It is a system programming language based on ALGOL 68 but with data types and operators aligned to those offered by the 2900...

 that was used to write the ICL VME operating system and much other system software on the ICL 2900 Series
ICL 2900 Series
The ICL 2900 Series was a range of mainframe computer systems announced by the UK manufacturer ICL on 9 October 1974. The company had started development, under the name "New Range" immediately on its formation in 1968...

 was a direct derivative of Algol 68. However, it omitted many of the more complex features, and replaced the basic modes with a set of data types that mapped directly to the 2900 Series hardware architecture.

Implementation specific extensions

ALGOL 68R(R) from RRE
Royal Radar Establishment
The name Royal Radar Establishment was given to the existing Radar Research Establishment following a visit by Queen Elizabeth II in 1957. Both names were abbreviated to RRE. The establishment had been formed, under its first name, in 1953 by merging the Telecommunications Research Establishment ...

 was the first ALGOL 68 subset implementation,
running on the ICL 1900
ICT 1900 series
ICT 1900 was the name given to a series of mainframe computers released by International Computers and Tabulators and later International Computers Limited during the 1960s and '70s...

.
Based on the original language, the main subset restrictions were definition before use and no parallel processing.
This compiler was popular in UK
United Kingdom
The United Kingdom of Great Britain and Northern IrelandIn the United Kingdom and Dependencies, other languages have been officially recognised as legitimate autochthonous languages under the European Charter for Regional or Minority Languages...

 universities in the 1970s, where many computer science
Computer science
Computer science or computing science is the study of the theoretical foundations of information and computation and of practical techniques for their implementation and application in computer systems...

 students learnt ALGOL 68 as their first programming language; the compiler was renowned for good error messages.

ALGOL 68RS(RS) from RSRE
Royal Signals and Radar Establishment
The Royal Signals and Radar Establishment was a scientific research establishment within the Ministry of Defence of the United Kingdom, located primarily at Malvern in Worcestershire. It was formed in 1976 in an amalgamation of earlier research establishments including the Royal Radar Establishment...

 was a portable compiler system written in ALGOL 68RS (bootstrapped from ALGOL 68R), and implemented on a variety of systems including the ICL 2900
ICL 2900 Series
The ICL 2900 Series was a range of mainframe computer systems announced by the UK manufacturer ICL on 9 October 1974. The company had started development, under the name "New Range" immediately on its formation in 1968...

/Series 39
ICL Series 39
The ICL Series 39 was a range of mainframe and minicomputer computer systems released by the UK manufacturer ICL in 1985.- Origins :The Series 39 range was based upon the New Range concept and the VME operating system from the company's ICL 2900 line, and was introduced as two ranges:* Series 39...

, Multics
Multics
Multics was an influential early time-sharing operating system. The project was started in 1964 in Cambridge, Massachusetts...

 and
DEC VAX/VMS
VAX
VAX was an instruction set architecture developed by Digital Equipment Corporation in the mid-1970s. A 32-bit complex instruction set computer ISA, it was designed to extend or replace DEC's various Programmed Data Processor ISAs...

.
The language was based on the Revised Report, but with similar subset restrictions to ALGOL 68R.
This compiler survives in the form of an Algol68-to-C compiler.

In ALGOL 68S(S) from Carnegie Mellon University
Carnegie Mellon University
Carnegie Mellon University is a private research university in Pittsburgh, Pennsylvania, United States....

 the power of parallel processing was improved by adding an orthogonal extension, eventing. Any variable declaration containing keyword event made assignments to this variable eligible for parallel evaluation, i.e. the right hand side was made into a procedure which was moved to one of the processors of the C.mmp
C.mmp
The C.mmp was an early MIMD multiprocessor system developed at Carnegie Mellon University by William Wulf . The notation C.mmp came from the PMS notation of Bell and Newell, where a CPU was designated as C and a variant was noted by the dot notation; mmp stood for Multi-Mini-ProcessorSixteen...

 multiprocessor system. Accesses to such variables were delayed after termination of the assignment.

Cambridge
University of Cambridge
The University of Cambridge is a public research university located in Cambridge, United Kingdom. It is the second-oldest university in both the United Kingdom and the English-speaking world , and the seventh-oldest globally...

 ALGOL 68C
ALGOL 68C
The ALGOL68C computer programming language compiler was developed for the CHAOS OS for the CAP capability computer at Cambridge University in 1971 by Stephen Bourne and Michael Guy as a dialect of ALGOL 68. Other early contributors were Andrew D. Birrell and Ian Walker.The initial compiler was...

(C) was a portable compiler that implemented a subset of ALGOL 68, restricting operator definitions and omitting garbage collection, flexible rows and formatted transput.

ALGOL 68G
ALGOL 68G
ALGOL68G or Algol 68 Genie is a recent ALGOL 68 compiler-interpreter. ALGOL68G is a nearly full implementation of ALGOL 68 as defined by the Revised Report and also implements partial parametrisation, which is an extension of ALGOL 68. After successful parsing of an entire source program, the...

(G) by M. van der Veer is an ALGOL 68 implementation for today's computers and operating systems. A minor restriction is that (formatted) transput does not fully conform to the Revised Report.

"Despite good intentions, a programmer may violate portability by inadvertently employing a local extension. To guard against this, each implementation should provide a PORTCHECK pragmat option. While this option is in force, the compiler prints a message for each construct that it recognizes as violating some portability constraint."http://www.fh-jena.de/~kleine/history/languages/Algol68-RR-HardwareRepresentation.pdf

Quotes

  • ... The scheme of type composition adopted by C owes considerable debt to Algol 68, although it did not, perhaps, emerge in a form that Algol's adherents would approve of. The central notion I captured from Algol was a type structure based on atomic types (including structures), composed into arrays, pointers (references), and functions (procedures). Algol 68's concept of unions and casts also had an influence that appeared later. Dennis Ritchie
    Dennis Ritchie
    Dennis MacAlistair Ritchie , was an American computer scientist who "helped shape the digital era." He created the C programming language and, with long-time colleague Ken Thompson, the UNIX operating system...

     Apr 1993.
  • ... C does not descend from Algol 68 is true, yet there was influence, much of it so subtle that it is hard to recover even when I think hard. In particular, the union type (a late addition to C) does owe to A68, not in any details, but in the idea of having such a type at all. More deeply, the type structure in general and even, in some strange way, the declaration syntax (the type-constructor part) was inspired by A68. And yes, of course, "long". Dennis Ritchie
    Dennis Ritchie
    Dennis MacAlistair Ritchie , was an American computer scientist who "helped shape the digital era." He created the C programming language and, with long-time colleague Ken Thompson, the UNIX operating system...

    , 18 June 1988
  • "Congratulations, your Master has done it" - Niklaus Wirth
    Niklaus Wirth
    Niklaus Emil Wirth is a Swiss computer scientist, best known for designing several programming languages, including Pascal, and for pioneering several classic topics in software engineering. In 1984 he won the Turing Award for developing a sequence of innovative computer languages.-Biography:Wirth...

  • The more I see of it, the more unhappy I become - E.W. Dijkstra, 1968
  • [...] it was said that A68's popularity was inversely proportional to [...] the distance from Amsterdam - Guido van Rossum
    Guido van Rossum
    Guido van Rossum is a Dutch computer programmer who is best known as the author of the Python programming language. In the Python community, Van Rossum is known as a "Benevolent Dictator For Life" , meaning that he continues to oversee the Python development process, making decisions where necessary...

  • 1980 quote: '[...] The best we could do was to send with it a minority report, stating our considered view that, "... as a tool for the creation of sophisticated programs, the language was a failure." [...] ' - C. A. R. Hoare, Oct 1980, re: "Dec 1968"
  • Original 1968 version: "[...] More than ever it will be required from an adequate programming tool that it assists, by structure, the programmer in the most difficult aspects of his job, viz. in the reliable creation of sophisticated programs. In this respect we fail to see how the language proposed here [Algol68] is a significant step forward: on the contrary, we feel that its implicit view of the programmer's task is very much the same as, say, ten years ago. This forces upon us the conclusion that, regarded as a programming tool, the language must be regarded as obsolete. [...]" Signed by: DIJKSTRA
    Edsger Dijkstra
    Edsger Wybe Dijkstra ; ) was a Dutch computer scientist. He received the 1972 Turing Award for fundamental contributions to developing programming languages, and was the Schlumberger Centennial Chair of Computer Sciences at The University of Texas at Austin from 1984 until 2000.Shortly before his...

    , DUNCAN, GARWICK, HOARE, RANDELL
    Brian Randell
    Brian Randell is a British computer scientist, and Emeritus Professor at the School of Computing Science, Newcastle University, U.K. He specializes in research in software fault tolerance and dependability, and is a noted authority on the early prior to 1950 history of computers.- Biography...

    , SEEGMUELLER, TURSKI, WOODGER. And then on Dec. 23, 1968, Jan V. Garwick

See also

  • ALGOL 60
    ALGOL 60
    ALGOL 60 is a member of the ALGOL family of computer programming languages. It gave rise to many other programming languages, including BCPL, B, Pascal, Simula, C, and many others. ALGOL 58 introduced code blocks and the begin and end pairs for delimiting them...

  • ALGOL Y
    ALGOL Y
    ALGOL Y was the name given to a speculated successor for the ALGOL 60 programming language that incorporated some radical features that were rejected for ALGOL 68 and ALGOL X...

  • ALGOL N
    ALGOL N
    ALGOL N is the name of a successor to ALGOL 60 designed in Japan with the aim of being as powerful as ALGOL 68 but as simple as ALGOL 60. It was proposed by Yoneda. Algol N tried to use extensibility in order to solve the problem that programming language designers faced when trying to make an...

  • ALGOL 68C
    ALGOL 68C
    The ALGOL68C computer programming language compiler was developed for the CHAOS OS for the CAP capability computer at Cambridge University in 1971 by Stephen Bourne and Michael Guy as a dialect of ALGOL 68. Other early contributors were Andrew D. Birrell and Ian Walker.The initial compiler was...

  • ALGOL 68G
    ALGOL 68G
    ALGOL68G or Algol 68 Genie is a recent ALGOL 68 compiler-interpreter. ALGOL68G is a nearly full implementation of ALGOL 68 as defined by the Revised Report and also implements partial parametrisation, which is an extension of ALGOL 68. After successful parsing of an entire source program, the...


  • C (programming language)
    C (programming language)
    C is a general-purpose computer programming language developed between 1969 and 1973 by Dennis Ritchie at the Bell Telephone Laboratories for use with the Unix operating system....

  • C++
    C++
    C++ is a statically typed, free-form, multi-paradigm, compiled, general-purpose programming language. It is regarded as an intermediate-level language, as it comprises a combination of both high-level and low-level language features. It was developed by Bjarne Stroustrup starting in 1979 at Bell...

  • Bourne shell
    Bourne shell
    The Bourne shell, or sh, was the default Unix shell of Unix Version 7 and most Unix-like systems continue to have /bin/sh - which will be the Bourne shell, or a symbolic link or hard link to a compatible shell - even when more modern shells are used by most users.Developed by Stephen Bourne at AT&T...

  • Bash

  • Steelman language requirements
    Steelman language requirements
    The Steelman language requirements were a set of requirements which a high-level general-purpose programming language should meet, created by the United States Department of Defense in The Department of Defense Common High Order Language program in 1978...

  • Ada (programming language)
    Ada (programming language)
    Ada is a structured, statically typed, imperative, wide-spectrum, and object-oriented high-level computer programming language, extended from Pascal and other languages...

  • Python (programming language)
    Python (programming language)
    Python is a general-purpose, high-level programming language whose design philosophy emphasizes code readability. Python claims to "[combine] remarkable power with very clear syntax", and its standard library is large and comprehensive...



External links

The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK