Programming language generations

Last updated

Programming languages have been classified into several programming language generations. [1] Historically, this classification was used to indicate increasing power of programming styles. Later writers have somewhat redefined the meanings as distinctions previously seen as important became less significant to current practice.

Contents

Generations

Second generation (2GL)

Examples: assembly languages

Second-generation programming language (2GL) is a generational way to categorize assembly languages. [2] [3] [4]

Third generation (3GL)

Examples: C, C++, Java, Python, PHP, Perl, C#, BASIC, Pascal, Fortran, ALGOL, COBOL

3GLs are much more machine-independent (portable) and more programmer-friendly. This includes features like improved support for aggregate data types and expressing concepts in a way that favors the programmer, not the computer. A third-generation language improves over a second-generation language by having the computer take care of non-essential details. 3GLs are more abstract than previous generations of languages, and thus can be considered higher-level languages than their first- and second-generation counterparts. First introduced in the late 1950s, Fortran, ALGOL, and COBOL are examples of early 3GLs.

Most popular general-purpose languages today, such as C, C++, C#, Java, and BASIC, are also third-generation languages, although each of these languages can be further subdivided into other categories based on other contemporary traits. Most 3GLs support structured programming. Many support object-oriented programming. Traits like these are more often used to describe a language rather than just being a 3GL.

Fourth generation (4GL)

Examples: ABAP, Unix shell, SQL, PL/SQL, Oracle Reports, R, Halide

Fourth-generation languages tend to be specialized toward very specific programming domains. [5] [6] 4GLs may include support for database management, report generation, mathematical optimization, GUI development, or web development.

Fifth generation (5GL)

Examples: Prolog, OPS5, Mercury, CVXGen [7] [8] , Geometry Expert

A fifth-generation programming language (5GL) is any programming language based on problem-solving using constraints given to the program, rather than using an algorithm written by a programmer. [9] They may use artificial intelligence techniques to solve problems in this way. Most constraint-based and logic programming languages and some other declarative languages are fifth-generation languages.

While fourth-generation programming languages are designed to build specific programs, fifth-generation languages are designed to make the computer solve a given problem without the programmer. This way, the user only needs to worry about what problems need to be solved and what conditions need to be met, without worrying about how to implement a routine or algorithm to solve them. Fifth-generation languages are used mainly in Artificial Intelligence or AI research. OPS5 and Mercury are examples of fifth-generation languages, [10] as is ICAD, which was built upon Lisp. KL-ONE is an example of a related idea, a frame language.

History

The terms "first-generation" and "second-generation" programming language were not used prior to the coining of the term "third-generation"; none of these three terms are mentioned in early compendiums of programming languages. The introduction of a third generation of computer technology coincided with the creation of a new generation of programming languages. The marketing for this generational shift in machines correlated with several important changes in what were called high-level programming languages, discussed below, giving technical content to the second/third-generation distinction among high-level programming languages as well while retroactively renaming Machine code languages as first generation, and assembly languages as second generation.

Initially, all programming languages at a higher level than assembly were termed "third-generation", but later on, the term "fourth-generation" was introduced to try to differentiate the (then) new declarative languages (such as Prolog and domain-specific languages) which claimed to operate at an even higher level, and in a domain even closer to the user (e.g. at a natural-language level) than the original, imperative high-level languages such as Pascal, C, ALGOL, Fortran, BASIC, etc.

"Generational" classification of high-level languages (third generation and later) was never fully precise and was later perhaps abandoned, with more precise classifications gaining common usage, such as object-oriented, declarative and functional. C gave rise to C++ and later to Java and C#; Lisp to CLOS; Ada to Ada 2012; and even COBOL to COBOL 2002. New languages have emerged in that "generation" as well.

See also

Related Research Articles

<span class="mw-page-title-main">Computer program</span> Instructions a computer can execute

A computer program is a sequence or set of instructions in a programming language for a computer to execute. It is one component of software, which also includes documentation and other intangible components.

A fourth-generation programming language (4GL) is a high-level computer programming language that belongs to a class of languages envisioned as an advancement upon third-generation programming languages (3GL). Each of the programming language generations aims to provide a higher level of abstraction of the internal computer hardware details, making the language more programmer-friendly, powerful, and versatile. While the definition of 4GL has changed over time, it can be typified by operating more with large collections of information at once rather than focusing on just bits and bytes. Languages claimed to be 4GL may include support for database management, report generation, mathematical optimization, GUI development, or web development. Some researchers state that 4GLs are a subset of domain-specific languages.

<span class="mw-page-title-main">Programming language</span> Language for communicating instructions to a machine

A programming language is a system of notation for writing computer programs. Programming languages are described in terms of their syntax (form) and semantics (meaning), usually defined by a formal language. Languages usually provide features such as a type system, variables, and mechanisms for error handling. An implementation of a programming language is required in order to execute programs, namely an interpreter or a compiler. An interpreter directly executes the source code, while a compiler produces an executable program.

Procedural programming is a programming paradigm, classified as imperative programming, that involves implementing the behavior of a computer program as procedures that call each other. The resulting program is a series of steps that forms a hierarchy of calls to its constituent procedures.

This is a "genealogy" of programming languages. Languages are categorized under the ancestor language with the strongest influence. Those ancestor languages are listed in alphabetic order. Any such categorization has a large arbitrary element, since programming languages often incorporate major ideas from multiple sources.

A high-level programming language is a programming language with strong abstraction from the details of the computer. In contrast to low-level programming languages, it may use natural language elements, be easier to use, or may automate significant areas of computing systems, making the process of developing a program simpler and more understandable than when using a lower-level language. The amount of abstraction provided defines how "high-level" a programming language is.

A programming paradigm is a relatively high-level way to conceptualize and structure the implementation of a computer program. A programming language can be classified as supporting one or more paradigms.

In computer science, declarative programming is a programming paradigm—a style of building the structure and elements of computer programs—that expresses the logic of a computation without describing its control flow.

The label of second-generation programming language (2GL) is a generational way to categorize assembly languages. They belong to the low-level programming languages.

A fifth-generation programming language (5GL) is a high-level programming language based on problem-solving using constraints given to the program, rather than using an algorithm written by a programmer. Most constraint-based and logic programming languages and some other declarative languages are fifth-generation languages.

In computer software, a general-purpose programming language (GPL) is a programming language for building software in a wide variety of application domains. Conversely, a domain-specific programming language (DSL) is used within a specific area. For example, Python is a GPL, while SQL is a DSL for querying relational databases.

<span class="mw-page-title-main">History of programming languages</span>

The history of programming languages spans from documentation of early mechanical computers to modern tools for software development. Early programming languages were highly specialized, relying on mathematical notation and similarly obscure syntax. Throughout the 20th century, research in compiler theory led to the creation of high-level programming languages, which use a more accessible syntax to communicate instructions.

<span class="mw-page-title-main">Boolean data type</span> Data having only values "true" or "false"

In computer science, the Boolean is a data type that has one of two possible values which is intended to represent the two truth values of logic and Boolean algebra. It is named after George Boole, who first defined an algebraic system of logic in the mid 19th century. The Boolean data type is primarily associated with conditional statements, which allow different actions by changing control flow depending on whether a programmer-specified Boolean condition evaluates to true or false. It is a special case of a more general logical data type—logic does not always need to be Boolean.

In computer science, a relational operator is a programming language construct or operator that tests or defines some kind of relation between two entities. These include numerical equality and inequalities.

Programming languages are used for controlling the behavior of a machine. Like natural languages, programming languages follow rules for syntax and semantics.

The following outline is provided as an overview of and topical guide to computer programming:

This article compares the syntax of many notable programming languages.

A third-generation programming language (3GL) is a high-level computer programming language that tends to be more machine-independent and programmer-friendly than the machine code of the first-generation and assembly languages of the second-generation, while having a less specific focus to the fourth and fifth generations. Examples of common and historical third-generation programming languages are ALGOL, BASIC, C, COBOL, Fortran, Java, and Pascal.

References

  1. "Generation of Programming Languages". GeeksforGeeks. 2017-10-22. Retrieved 2025-01-15.
  2. "Computer Hope, Generation languages".
  3. Brookshear, J. Glenn (2012). Computer science : an overview (11th ed.). Addison-Wesley. pp. 240–241. ISBN   978-0-13-256903-3.
  4. Vass, Péter. "Programming Language generations and Programming Paradigms" (PDF). Archived from the original (PDF) on 2020-01-29.
  5. 35th Hawaii International Conference on System Sciences - 1002 Domain-Specific Languages for Software Engineering. Archived May 16, 2011, at the Wayback Machine .
  6. Arie van Deursen; Paul Klint; Joost Visser (1998). "Domain-Specific Languages: An Annotated Bibliography". Archived from the original on 2009-02-02. Retrieved 2009-03-15.
  7. NAE, The Bridge, Autonomous Precision Landing of Space Rockets, December 19, 2016, Author: Lars Blackmore.
  8. CVXGEN: Code Generation for Convex Optimization, cvxgen.com, December 4, 2013.
  9. Dong, Jielin, ed. (2007). Network dictionary. Saratoga, Calif.: Javvin Technologies, Inc. p. 195. ISBN   9781602670006.
  10. E. Balagurusamy, Fundamentals of Computers, Mcgraw Hill Education (India), 2009, ISBN   978-0070141605, p. 340.