Programming language is a language developed to communicate with machine or computer. Programmming languages are used to
express algorithms and to interact with machine more precisely with computers. Programming languages are used to write programs
that performs some kind of task/operations.
Programming language has two parts one is syntax and second is semantic. Syntax means what is the form of programming language or the
rules or grammar that governs the way of writing the program. Semantic means what is the meaning of an expression in the program.
Take an example :
c=a+b;
Here '=' is an assignment operator and ';' semicolon specifies termination of the statement. This is known as syntax of the program.
Here the meaning of statement is add 'a' and 'b' and store the result of addition in 'c'. This is known as semantic of the program.
There is a big list of types of programming languages but we are discussing here 3 mejor types of programming languages:
Low level programming language
High level programming language
Very high level programming language
Low level programming language:
Low level programming language is closely related to the machine in which it is built i.e. low level programming languages are machine oriented programming language and it requires intensive and extensive knowledge of computer hardware and its configurations.
Low level programming languages needs no compiler or interpreter to be converted into machine code. A program written in low-level language can be made to run very quickly, and with a very small memory space.Low-level languages are simple, but are considered difficult to use due to various technical information must be remembered.
Low-level languages are further divided into two categories: First generation and second generation.
Machine language: Machine language is the only language which is directly understood by computer and it does not require any kind of translator program. It is also known as machine code and it is t combination of various 0's and 1's. For example, a program instruction may look like this:
1011000111101
It is considered to the first generation language.It is not an easy language for you to learn because of its difficult to understand.
Its only advantage is that program of machine language run very fast because no translation program is required for the CPU.
Assembly Language:
It is the first step to improve the programming structure.Computer can handle numbers and letters, therefore some combination of letters is substituted to numbers of machine code.
The set of symbols and letters forms the Assembly Language and a translator program is required to translate the Assembly Language to machine language. This translator program is called `Assembler’. It is considered to be a second-generation language.
Here is an example of assembly language to reverse the bits of a byte:
ORG $400
MOVE.B Test,D0 Get the string to reverse
MOVE.B #7,D7 Use D7 as a loop counter for 8 cycles
CLR.L D1 Use D1 to catch the reversed bits
Shft LSL.B #1,D0 Shift the byte one place left � catch ms bit
ROXR.B #1,D1
DBRA D7,Shft Repeat 8 times
STOP #$2700 Stop execution
Test DC.B %11001010 Test string
High-level Programming language:
As we learned that machine language nad assembly language require a deep knowledge of computer hardware and configurations. On the other hand high level languages just need knowledge of english words and logic of the problem irrespective of the type of computer you are using.
High level languages are human understandable language and it needs to be converted to machine language for the computer to understand.
Higher level languages are problem-oriented languages because the instructions are suitable for solving a particular problem. For example COBOL (Common Business Oriented Language) is mostly suitable for business oriented language where there is very little processing and huge output. There are mathematical oriented languages like FORTRAN (Formula Translation) and BASIC (Beginners All-purpose Symbolic Instruction Code) where very large processing is required.
The first high-level programming languages were designed in the 1950s. Now there are dozens of different languages, including Ada, Algol, BASIC, COBOL, C, C++, FORTRAN, LISP, Pascal, and Prolog.
Higher level languages have a major advantage over machine and assembly languages that higher level languages are easy to learn and use. It is because that they are similar to the languages used by us in our day to day life.
very high-level programming language:
A very high-level programming language is a programming language with a very high level of abstraction (abstraction - a concept or idea not associated with any specific instance), mainly used as a professional programmer productivity tool.
Very high-level programming languages are usually limited to a very specific application, purpose, or type of task. For this reason, very high-level programming languages are often referred to as goal-oriented programming languages.
No comments:
Post a Comment