COMPUTER PROGRAMMING LANGUAGE


Introduction

A language is a medium through which we communicate with each other. While communicating we use such a language that is understood by both. Sometimes we take the help of interpreter to communicate when we both don’t know languages of each other.

Communicating to a computer is not taking like the person to person. It means giving a set of instructions to a computer and the computer follows the instructions given by us. We cannot give instructions to a computer in human language like Nepali, English, etc. To interact with the computers, we need a computer language. An artificial language used for writing instructions or programs is known as computer language. A computer language is known as programming language. A programming language provides a way of giving instructions to the computer. We don’t use programming language in our everyday conversions. We can use a programming language to instruct a computer when we need.

  • The set of commands that are used to give instruction and
  • The manner in which these commands are put together.

Since a computer understands binary digits, we can use binary number to instruct the computer. The instructions written in the binary number system is known as machine language. Machine language is directly understood by the computer. In the early time, Charles Babbage had used machine language to write instructions for his Differential and Analytical engines. However, writing programs in machine language is very difficult. Therefore, many other artificial languages have been developed for instructing computers. Expect machine language, a computer does not directly understand any other computer languages so the instructions written in other computer languages must be translate into machine language. This translating task is carried out by Translator i.e. Language Processor.

Computer program
A program is set of an instruction which tells the computer what to do. A program directs the computer to perform a particular task and produce the desired result. A person who writes a program for computers is known as a programmer. The process of writing set of instructions in a computer language is called programming.

Types of computer languages
The computer languages are divided into two categories. They are
a. Low-level language
b. High-level Language

a. Low-level language
Low-level language is machine dependent language. The program written for one computer in low level language cannot be used in another computer. This makes it difficult to learn and use, as the programmer must have the in-depth knowledge of different computers to write programs in a low level language.

There are two types of low level languages. They are
i. Machine Level Language (MLL)
ii. Assembly Language (AL)

i. Machine Level Language
Machine level language is the first generating language. Machine level language is the only language that a computer understands directly without any translator program. Machine level language was used in the earliest machines and computers. Machine level language is difficult to write programs in a machine level language. Nowadays nobody writes programs in machine Level Language.

Advantages of machine level language
  • No language processor is required.
  • Programs written in machine level language run very fast.

Disadvantages of machine level language
  • Machine level language is machine oriented language i.e. machine dependent. The program written in one computer cannot be run in another computer.
  • To write program using this language, a programmer has to know the details of computer hardware of the computer.
  • A programmer has to remember a lot of codes to write a program which may cause error in the program.
  • A program becomes lengthy and difficulty of debugging.

ii. Assembly Language
This is second generation language. Assembly language was developed by the programmers to overcome the drawbacks of the machine level language. Assembly language uses letter, words and symbols instead of binary digits. These letter, words and symbol are called mnemonics. Assembly language is little bit easier than machine language. Since Assembly language is also machine dependent language the programmers need to know many mnemonics for each computer. The programs written in this language need to convert into machine language.

Advantages of assembly language
  • The programming in assembly language is easier than machine language.
  • Debugging and modifying programs are easier than machine language.

Disadvantage of assembly language
  • Assembly language is also machine dependent.
  • Programmers have to remember a lot of mnemonics codes for different types of machine.

b. High level language
High level language is a simple languages that uses English and mathematical symbols for its program construction. High level language is considered as Third Generation Language. High level languages are machine independent languages. Hence, programmers do not need to worry about the hardware used in the computer on which they are writing programs. The programs written in a high level language in one computer can be run in any other computer. The programs written in HLL need to translate into machine language. This translation is done by either Compiler or an Interpreter.
BASIC, COBOL, FORTRAN, PASCAL, C, C++, JAVA etc., are some examples of HLLs.

Advantages of high level language
  • High level language is machine independent and program oriented language.
  • High level language is easy to learn and use.
  • Writing the program in a HLL in easy.
  • Debugging is easy in HLL.

0 comments:

Post a Comment