The Programming Language

A programming language is a vocabulary and set of grammatical rules for instructing a computer or computing device to perform specific tasks. The term programming language usually refers to high-level languages, such as BASICCC++COBOLJavaFORTRANAda, and Pascal.

Each programming language has a unique set of keywords (words that it understands) and a special syntax for organizing program instructions.

Today I’m gonna be describing the 5 generations of programming language that we have right now.

FIRST GENERATION LANGUAGE (1GL) : What is the first generation programming language that I’m talking about so much? well, a first generation (programming) language (1GL) is a grouping of programming languages that are machine level languages used to program first-generation computers. The instructions were given through the front panel switches of these computers, directly to the CPU. There was originally no compiler or assembler to process the instructions in 1GL.

The instructions in 1GL are made of binary numbers, represented by 1s and 0s. This makes the language suitable for the understanding of the machine but very much more difficult to interpret and learn by the human programmer.

Also, known as a first generation language.

The main advantage of programming in 1GL is that the code can run very fast and very efficiently, precisely because the instructions are executed directly by the CPU. One the main disadvantages of programming in a low level language is that when an error occurs, the code is not as easy to fix.

The program is written as binary instructions, consisting of zeros and ones. This language is very much adapted to a specific computer and CPU, and code portability is therefore significantly reduced in comparison to higher level languages.

Modern day programmers still occasionally use machine level code, especially when programming lower level functions of the system, such as drivers, interfaces with firmware and hardware devices. Modern tools, such as native-code compilers are used to produce machine level from a higher-level language.

Image result

Related image

SECOND GENERTION LANGUAGE (2GL) : Okay, let’s talk about the second programming language now, shall we? 

A second generation (programming) language (2GL) is a grouping of programming languages associated with assembly languages. Unlike the first generation languages, programs can be written symbolically, using English words (also known as mnemonics), in a way that a human can understand and are subsequently converted into machine language by an assembler.

Assembly languages are specific to computer and CPU. The term is used in the distinction between Machine Languages (1GL) and higher-level programming languages (3GL, 4GL, etc.)

Also known as a 2nd generation language.

Assembly Languages originated in the 1940s, and are attributed to the efforts of the American naval officer Grace Hopper, with the introduction of the FLOW-MATIC language for the ENIAC computer.

2GL are mostly used for the implementation of low-level kernels and drivers and for performance-oriented and processing-intensive applications such as computer games, graphic manipulation applications and video editing applications.

The symbolic representation of machine Instructions, registers and memory addresses allows the programmer to produce a human-readable program. For the computer to understand the program it must be converted to a machine readable format using an Assembler. The Assembler usually converts the Mnemonics via a one-to-one mapping from the mnemonic representation to machine language, for a particular processor family and environment.

Assemblers allow for easier debugging of the program, and also introduce more advanced programming mechanisms such as macro Programming and structured Programming.

Concrete examples of assembly languages include x86, MIPS, ARM, SPARC as well as a whole bunch of more obscure research systems like RISC-V.

Here’s an example of some MIPS code which roughly corresponds to the following function (but probably not dealing with overflow correctly):

  1. int foo(int a, int b) {
  2. int c = a + 3 * b;
  3. return c * 10;
  4. }


in MIPS:

  1. addi $t0, $0, 3
  2. mult $a1, $t0
  3. mflo $t0
  4. addu $t0, $t0, $a0
  5. addi $t1, $0, 10
  6. mult $t0, $t1
  7. mflo $v0


(Also, I haven’t done any MIPS in a while or tested this code, so it might be completely wrong! but I’m trying my best)

Image result for second programming language
THIRD GENERATION LANGUAGE (3GL) :  Now let’s move onto the third generation programming language.
A third generation (programming) language (3GL) is a grouping of programming languages that introduced significant enhancements to second generation languages, primarily intended to make the programming language more programmer-friendly.

English words are used to denote variables, programming structures and commands, and Structured Programming is supported by most 3GLs. Commonly known 3GLs are FORTRAN, BASIC, Pascal and the C-family (C, C+, C++, C#, Objective-C) of languages.

Also known as a 3rd generation language, or a high-level programming language.                                                                                                                                                                                                                                                                                                                                                       Moving away from the cryptic commands of Assembly Language and one step below Fourth Generation Languages, programmers in 3GLs are favored by using aggregate data types, variable names and the ability to define sections of code as subroutines. The program in 3GL is called the Source Program or Source Code and it subsequently converted by a specialized program, the Compiler, to Object Code, understandable by the specific computer and CPU.

Since the introduction of the Compiler in 1952, hundreds of 3GLs have been developed, specifically providing benefits for programmers of applications serving various business and scientific domains. In 1957, IBM created FORTRAN (FORmula TRANslator) to facilitate computerized mathematically-intensive scientific research. COBOL (COmmon Business Oriented Language) was instrumental in spurring a surge of programs serving the business arena, with its enhanced ability to provide record keeping and data management services.

Most of the general purpose programming languages used today such as C, C++, C# and Java are 3GLs.
Image result for third generation programming language
Image result for third generation programming language
FOURTH GENERATION LANGUAGE (4GL) :

A fourth generation (programming) language (4GL) is a grouping of programming languages that attempt to get closer than 3GLs to human language, form of thinking and conceptualization.

4GLs are designed to reduce the overall time, effort and cost of software development. The main domains and families of 4GLs are: database queries, report generators, data manipulation, analysis and reporting, screen painters and generators, GUI creators, mathematical optimization, web developmentand general purpose languages.

Also known as a 4th generation language, a domain specific language, or a high productivity language.

4GLs are more programmer-friendly and enhance programming efficiency with usage of English-like words and phrases, and when appropriate, the use of icons, graphical interfaces and symbolical representations. The key to the realization of efficiency with 4GLs lies in an appropriate match between the tool and the application domain. Additionally, 4GLs have widened the population of professionals able to engage in software development.

Many 4GLs are associated with databases and data processing, allowing the efficient development of business-oriented systems with languages that closely match the way domain experts formulate business rules and processing sequences. Many of such data-oriented 4GLs are based on the Structured Query Language (SQL), invented by IBM and subsequently adopted by ANSI and ISO as the standard language for managing structured data.

Most 4GLs contain the ability to add 3GL-level code to introduce specific system logic into the 4GL program.

The most ambitious 4GLs, also denoted as Fourth Generation Environments, attempt to produce entire systems from a design made in CASE tools and the additional specification of data structures, screens, reports and some specific logic.

Some examples of 4GL are: database query language e.g.SQLFocusMetafontPostScriptSIDL-PVWAVEGaussMathematica, and data-stream languages such as AVSAPEIris Explorer.

 

Image result for fourth generation programming language

 

Image result for fourth generation programming language

Image result for fourth generation programming language
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FIFTH GENERATION LANGUAGE (5GL) : And finally we’ve come to the last part, The Fifth Generation programming language. 

A fifth generation (programming) language (5GL) is a grouping of programming languages build on the premise that a problem can be solved, and an application built to solve it, by providing constraints to the program (constraint-based programming), rather than specifying algorithmically how the problem is to be solved (imperative programming).

In essence, the programming language is used to denote the properties, or logic, of a solution, rather than how it is reached. Most constraint-based and logic programming languages are 5GLs. A common misconception about 5GLs pertains to the practice of some 4GL vendors to denote their products as 5GLs, when in essence the products are evolved and enhanced 4GL tools.

Also known as a 5th generation language.

The leap beyond 4GLs is sought by taking a different approach to the computational challenge of solving problems. When the programmer dictates how the solution should look, by specifying conditions and constraints in a logical manner, the computer is then free to search for a suitable solution. Most of the applicable problems solved by this approach can currently be found in the domain of artificial intelligence.

Considerable research has been invested in the 1980s and 1990s, into the development of 5GLs. As larger programs were built, it became apparent that the approach of finding an algorithm given a problem description, logical instructions and a set of constraint is a very hard problem in itself. During the 1990s, the wave of hype that preceded the popularization of 5GLs and predictions that they will replace most other programming languages, gave way to a more sober realization.

PROLOG (acronym for PROgramming LOGic) is an example of a Logical Programming Language. It uses a form of mathematical logic (predicate calculus) to solve queries on a programmer-given database of facts and rules.

                                                                                                                                                                                                                                                                                                                                         So this was a short description about all generations of programming language.

Leave a comment