Around the world language is a source of communication among human beings. Similarly, in order to communicate with computer user also needs to have a language, that should be understandable by the computers. For the purpose different languages are developed for performing different types of work on the computer.
Mainly there are two types of computer languages.
Low Level Computer Languages
These are machine codes or close to it. Computer cannot understand instruction given in high level languages or in English. It can only understand and execute instructions given in the form of machine languages i.e. the binary number 0 and 1. There are two types of low level computer language.
The lowest and most elementary language and was the first type of programming language to be developed. Mache language is basically the only language which computer can understand. In fact, a manufacturer designs a computer to obey just one language, its machine code, which is represented inside the computer by a string of binary digits (bits) 0 and 1. The symbol 0 stand for the absence of an electric pulse and 1 for the presence of an electric pulse. Since a computer is capable of recognizing electric signals, therefore, it understands machine language.
The set of binary codes which can be recognize by the computer is known as the machine code instruction set. A machine language instruction consists of an operation code one or more operands. The operation code specifies that operation that is to be performed e.g. read, record etc. the operands identify the quantities to be operated on e.g. the numbers to be added or the locations where data are stored. But, it is almost impossible to write programs directly in machine code. For this reason, programs are normally written in assembly or high level languages and then are translated in the machine language by different translators.
- It makes fast and efficient use of the computer
- It requires no translator to translate the code i.e. directly understood by the computer.
- All operation codes have to be remembered
- All memory addresses have to be remembered
- It is hard to amend or find errors in a program written in the machine language
- These languages are machine dependent i.e. a particular machine language can be used on only one type of computer.
It was developed to overcome some of the many inconveniences of machine language. This is another low level but a very important language in which operation codes and operands are given in the form of alphanumeric symbols instead of 0’s and 1’s. These alphanumeric symbols will be known as mnemonic codes and can have maximum up to 5 letter combinations e.g. ADD for addition, SUB for subtraction, START LABEL etc. because of this feature it is also known as “Symbolic Programming Language”. This language is very difficult and needs a lot of practice to master it because very small English support is given. This symbolic language helps in compiler orientations. The instructions of the assembly language will also be converted to machine codes by language translator to be executed by the computer
- It is easier to understand and use as compared to machine language
- It is easy to locate and correct errors
- It is modified easily
- Like machine language it is also machine dependent
- Since it is machine dependent, there programmer should have the knowledge of he hardware also.
Computer High Level Languages
High level computer languages give formats close to English language and the purpose of developing high level languages is to enable people to write programs easily and in their own native language environment (English). High-level languages are basically symbolic languages that use English words and/or mathematical symbols rather than mnemonic codes. Each instruction in the high level language is translated into many machine language instructions thus showing one-to-many translation.
- Problem-Oriented Language: These are languages used for handling specialized types of data processing problems where programmer only specifies the input/output requirements and other relative information of the problem, that are to be solved. The programmer does not have to specify the procedure to be followed in solving that particular problem.
- Procedural Language: These are general purpose languages that are designed to express the logic of a data processing problem.
- Non-procedural Language: Computer Programming Languages that allow users and professional programmers to specify the results they want without specifying how to solve the problem.
Selection of a Computer Language
There are many high-level languages in use today. The choice of language depends on type and complexity of the problem.
- Purpose e.g. business, educational, scientific.
- Facilities provided e.g. meaningful variable names, control and data structures, error checking facilities.
- Ease of learning and use.
- Portability – if a program is to he used on or in more than one system.
- Popularity – availability of compilers/interpreters.
- Documentation provided.
Types of High Level Languages
Many languages have been developed for achieving different variety of tasks, some are fairly specialized others are quite general purpose. These are categorized according to their use as:
Algebraic Formula-Type Processing. These languages are oriented towards the computational procedures for solving mathematical and statistical problems. Examples are
- BASIC (Basic All Purpose Symbolic Instruction Code)
- FORTRAN (Formula Translation).
- PL/1 (Programming Language, Version 1).
- ALGOL (Algorithmic Language).
- APL (A Programming Language).
Business Data Processing. These languages emphasize their capabilities for maintaining data processing procedures and files handling problems. Examples are:
- COBOL (Common Business Oriented Language)
- RPG (Report Program Generator).
String and List Processing. These are used for string manipulation including search for patterns, inserting and deleting characters. Examples are: LISP (List Processing).
Multipurpose Language. A general purpose language used for algebraic procedures, data and string processing. Examples are:
- Pascal (after the name of Blaise Pascal).
- PL/1 (Programming Language, version 1).
- C language.
Simulation: These may be written in algebraic or multipurpose languages. Examples are:
- SPSS (Statistical Package System Simulator).
- GPSS (General Purpose System Simulator).
Advantages: Following are the advantages of a high level language:
- User-friendly (people based)
- Similar to English with vocabulary of words awl symbols therefore it is easier to learn.
- They require less time to write
- They are easier to maintain
- Problem oriented’ rather than ‘machine’ based
- Shorter than their low-level equivalents. One statement translates into many machine code instructions.
- Program written in a high-level equivalent can he translated into many machine language and therefore can run on every computer for which there exists an appropriate translator.
- It is independent of the machine on which it used i.e. programs developed in high level language can be run on any computer.
Disadvantages: There are certain disadvantages also Inspite these disadvantages high-level languages have proved their worth. The advantages out-weigh the disadvantages by far, for most applications. These are:
- A high-level language has to be translated into the -machine language by a translator and thus a price in computer time is paid.
- The object code generated by a translator might be inefficient compared to an equivalent assembly language program