Program| programming language

 


Programming concept

Program

The Program is the set of instructions that command the computer to perform a particular operation or a specific task.

A program is composed of a list of the instruction (s) to perform a specific job. Instruction is also called a statement. Generally, a statement is an instruction to do only one task.

The group of statements is composed together to form a program.

Concept of Programming Statement

A statement is a complete direction instructing the computer to carry out some tasks. For example, in C language, simple statements are those statements which are finally ended with the semicolon,

ready to perform some action. For example,

printf ("Value of x is %d",x);

Qualities of Good Program

A program can be considered as a good program if it contains the following qualities:

  1. A program should be correct.
  2. It should produce of desired output.
  3. It should be easy to understand.
  4. It should be easy to maintain and update.
  5. It should be flexible.i.e. it should be able to operate with a wide range of possibilities.
  6. It should have an easier user interface.



Introduction of programming language

Programming

the process of writing a program following the grammar of the programming language. When write a program, we've to follow the grammatical rules. When such statements are written in chronological order then the program is created, which finally performs some tasks,

We might need to use character, string, or number to make a statement, which can express some sks i.e. simply saying it is a way to create a sequence of instructions to enable the computer to do something that can be termed as programming.

Programming Language

Why do we need language? The answer simply ends with a single term to communicate. In the same context, the programming language is also used to communicate with the computer. The programming language provides a set of symbols, characters, strings, numbers, variables, constants that helps us to make the statement. A statement is used to express the task that we want to perform that's why we need a programming language.

So, we can simply define the programming language as, and it is the set of written symbols and codes that instruct the computer hardware to perform specified tasks. It is simply the coded language used by programmers to write instructions that a computer can understand to do what the programmer user wants.

Types of Programming Language

There are two types of programming language, which can be categorized into the following ways:

Low-level language

1. Machine language or First-generation language [1GL]

2. Assembly language or Second-generation language[2GL] 

High-level language

1. Procedural-oriented language or Third generation language [3GL] 

2. Problem-Oriented language or Fourth generation language [4GL]

3. Natural language or Fifth generation language [5GL]

Low level language

Low-level languages are difficult and time-consuming to develop the program. It is a machine dependent language. Programmers require detailed knowledge of hardware architecture to use this language. It is more efficient to develop hardware-oriented software.

Low-level language can be further categorized as:

1.Machine Language (IGL)

2.Assembly Language (2GL)

Machine Language (1GL)

A machine language consists of strings of binary numbers (i.e., 0s and 1s) and it is the only language, the processor directly understands. 

Advantages of using Machine language:

1. It is the only language, which is directly understood by the computer.

2. A language translator is not required.

Disadvantages of using Machine language

1. It is tedious, difficult and time-consuming to develop and debug programs. 

2. All operation codes have to be remembered. 

3. All memory address has to be remembered.

Assembly Language (2GL)

Assembly language is also a low-level language because designing a program, programmer detailed knowledge of hardware specifications. This language uses mnemonics code operation code like ADD, SUB, DIV) in place is 0s and 1s.

Advantages of using Assembly language:

1. It is easier to develop and debug the program compared to machine language due to the use of mnemonics code.

2. Programming is simplified i.e. programmer does not need to know the exact storage location of data and instruction.

Disadvantages of using Assembly language:

1. Additional software, the assembler is required to the translated program into object code. It is also a machine dependent language.

2. Programmers require detailed knowledge of hardware architecture.

High-level Language

Instruction of this language closely resembled to human language or English like words or sentences and mathematical notations to perform the task. The high-level language is easier to learn. It requires less time to write and it is easier to maintain the errors. The high-level language is converted into machine language by one of the two different languages translator programs, interpreter or compiler.

High-level language can be further categorized as:

  • Procedural-oriented language (3GL)
  • Problem-oriented language (4GL) 
  • Natural language (5GL)


Procedural-oriented Language (3GL)

This language uses simple English and mathematical statements to develop a progr languages such as Pascal, BASIC, COBOL, C, FORTRAN. These languages are desis the logic and the procedure of a problem. Because of their flexibility, procedural language are able to solve a variety of problems.

Problem-oriented (Fourth Generation) Language (4GL)

The 4GL is a non-procedural or problem-oriented language. It allows the users to specify what the output should be, without describing all the details of how the data should be manipulated to produce the result. This is one step ahead of 3GL. These are result-oriented and include database query languages. There are fewer options for programmers, but the programs are much easier to write than in lower-level languages. 4GL programs are also needed to be translated either by compiler or interpreter.

Examples of 4GL are Visual Basic, C#, PHP.

Natural (Fifth Generation) Language (5GL)

The natural language uses simple statements of common communication languages where we could write statements that would look like normal sentences. For example, instead of the odd-looking code, you would write "who are the salesmen with sales over Rs. 20,000 last month?". It is still in the developing stage Computer scientists are working hard for developing such languages. However, a programming language named PROLOG is in use, which would support 5GL to some extent.

List of Some High-level Programming Languages

  • C
  • C++
  • Java
  • Pascal
  • COBOL
  • ALGOL
  • Python
  • BASIC
  • C#
  • FORTRAN
  • Scheme
  • VB.Net
  • Java Script
  • PHP
  • Visual Basic




Author Spotlight

Santosh Chapagain
Gmail: chapagainsantoshcs@gmail.com
Phone no: +977-9863512955

Post a Comment

1 Comments