24. Language Generations

Throughout this mini-website, a mention has been made of which generation a certain type of language belongs.

This is because computer programming is now more than a half a century old and over that time the languages developed reflected the technology available at that time.

This does not mean that 1st generation languages are obsolete, far from it, each generation still exists today depending on the level of 'abstraction' being used. Abstraction means how far away the programmer needs to be from knowing the internal details of the processing machine.

1st generation (1GL)

In the first days of computing there were no handy tool with which to write software - code had to be written in machine language. These days this is used mainly by CPU engineers who have to write the micro-code within a CPU.

2nd generation (2GL)

Assembly languages belong to this generation. 2GL languages are more readable than 1GL because 'mnemonics' are used to help programmers write code. Instead of writing a hex number, as in machine language, they write something like 'LDA' meaning 'Load Accumulator'.

2GL languages are CPU specific.

3rd Generation (3GL)

This generation introduces the idea of named variables to represent data in specific memory locations. Data types are no longer simple binary numbers but can be more 'abstract' data structures such as linked lists and arrays.

Also 3GL language source code is far more portable that 2GL code. A compiler / linker is used to target specific CPU families without having to change source code.

The programmer does not have to know the internal details of the CPU - the compiler / linker takes care of all that detail. And so the level of abstraction is higher than 2GL

4th Generation (4GL)

Yet another level of abstraction. The idea of 4GL languages was to avoid writing source code. You let the system write it for you.

The technology allows you to lay out a problem in some way and the system automatically generates the underlying source code for you.

4GL languages tend to be application specific. For example 'Simulink' is a simulation / modeling environment in which you can lay out a mathematical model as various graphical blocks joined by lines. Once the model is set up, compiling the model results in the correct source code being output.

You will often hear the term 'rapid prototyping' when 4GL languages are involved.

5th Generation (5GL)

At this level, the programmer no longer tells that computer how to solve a problem. He simply states a goal for the computer to solve.

Many declarative languages claim to be 5th generation because they are 'goal seeking' systems.

However, we have not really reached this level as yet as the application tends to be very specific and the goals narrowly defined.

Challenge see if you can find out one extra fact on this topic that we haven't already told you

Click on this link: Language generations

 

Copyright © www.teach-ict.com