Generations Of Programming Languages


Published on

AQA AS Computing Comp2 Generations of programming languages.

Published in: Education, Technology
1 Comment
No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

Generations Of Programming Languages

  1. 1. Generations of Programming Languages
  2. 2. Classification of Prog Langs <ul><li>Computers can only understand binary. We have already covered how this binary code (a programme) is dealt with by the processor when we covered basic machine operation and the fetch execute cycle. </li></ul><ul><li>This binary programme is known as the first generation language. When computers were first made this was your only option. Since then programming languages have become increasingly detached from this original binary code with successive generations. You are required to be able to classify different programming languages. </li></ul>
  3. 3. What you need to be able to do <ul><li>With regards the Exam board there are 4 generations of programming language, you need to be able to identify the key characteristics of each and ideally give some examples. </li></ul>
  4. 4. First Generation (Machine Code) <ul><li>As already mentioned the processor can only deal with programs in the form of binary (1’s and 0’s). With a very simple computer setup such as a musical card it is often necessary to write your programme like this but generally it is far to tedious and hard for a human to understand. </li></ul><ul><li>You should note ALL the other generations of programming languages will convert your programme into this machine code. </li></ul><ul><li>Each different type of processor will have it’s own form of machine code. </li></ul>
  5. 5. Second Generation (Assembly) <ul><li>In recognition of how hard it is to code in binary the second generation programming languages were rapidly invented. The principle is very simple, it is much easier to remember/understand a short word than a binary number. Essentially the op-code is represented by a mnemonic which in some way describes the action of the machine code (such as save, mov, load, store, add). </li></ul><ul><li>Just like with machine code these instructions are specific to a particular family of processor. </li></ul>
  6. 6. Third Generation (most languages in use to develop software) <ul><li>Machine code is impractical and even Assembly language is very hard to use for larger programs as it is hard to track what exactly is going on. They are also very specific to individual processor families so would need to be re-written for the large number of processors out there (imagine a different copy of word for your dual core laptop to the old pentium 4 in the study). </li></ul><ul><li>Third generation languages address these problems somewhat and are relatively easy to program in compared to generation 1 and 2. </li></ul><ul><li>The program is written in a way which can be grouped and organised by the user with routines and sub-routines (remember ks3 control). These are then converted into machine code with a single line often representing several hundred lines of machine code. As a separate program converts your code into machine code it deals with the fact that the machine code might be for a different family of processor. </li></ul><ul><li>Java, php, C, C+, C#, Fortran, Cobol, Basic, Visual Basic, etc are all examples of third generation programming languages. </li></ul>
  7. 7. Fourth Generation <ul><li>Fourth generation programming languages are more aimed at problem solving. The key difference is that they are more concerned with what is to be done than the actual how. These are generally to do with accessing databases. They are probably the easiest of the four generations to read as they have been deliberately designed to reflect normal language and are often tolerant of errors. </li></ul><ul><li>Examples include Prolog, SQL, MySQL, etc </li></ul><ul><li>Because they are so far removed from first generation languages they tend to be very platform independent and willing to run on many different families of processor. </li></ul>
  8. 8. Summary (of section) <ul><li>System Software: operating Systems, Library programs, utility programs, language translators </li></ul><ul><li>Application software: general purpose, special purpose and bespoke. </li></ul><ul><li>Assemblers translate assembly code into machine code. </li></ul><ul><li>A high level language program is called source code. </li></ul><ul><li>A compiler translates source code into object code </li></ul><ul><li>An interpreter analyses each statement of the source code as it executes it. </li></ul><ul><li>Machine code, assembly languages, imperative languages and declarative languages. </li></ul>
  9. 9. Lunch sessions <ul><li>Which one is best, go to the vle and vote. </li></ul><ul><li>Upload your holiday homework now, sorry the system was down. </li></ul><ul><li>Warning of upcoming seating plan. </li></ul>