You are on page 1of 2

# Algorithm is a set of instructions or steps applied to a problem with a view to solve it.

In simple words we can say that algorithm is method of solving a problem. Pseudo code describes algorithm itself. Pseudo code makes no use of syntax of a specified programming language. So, it cannot be executed in a computer. But it contains almost the same detail as a programming language does and has the same structure. Algorithm Algorithm is group of instructions or a set of steps applied to solve a problem. An easy example of algorithm is a recipe in a cook book. When a problem is solved with the help of a computer, some specific instructions have to be given to it. That is why the study of algorithm constitutes an integral part of the computer science. When algorithm is applied in a computer, a number of elementary operations are combined together. For example, to solve a complex mathematical problem, some simple operations like subtractions and additions are applied. But applying algorithm to computer code is not so simple a matter. It is very tedious task to convert an algorithm in assembly language. However, use of high level languages like Java or C is much easier. The analysis of resources is required before designing an algorithm. Generally, big O notation is used for performing time and storage analysis. An algorithm is expressed with the help of natural languages, flowcharts, and pseudo code. Pseudo code Pseudo code is a method of representing algorithm. It has not a specific syntax to write a language which is used in programming language. Therefore it cannot be executed on a computer. A number of formats are available to write pseudo codes. They are mostly borrowed from the structures of popular languages like C, Lisp and FORTRAN etc. When details are not important, they are expressed in natural language. Algorithms are expressed in pseudo code as they are not understood by the programmers who are familiar with other languages of programming. Pascal is another language which is similar to pseudo code which makes the transformation of pseudo code to the target program code easier. Control structures such as WHILE, IF-THEN-ELSE, REPEATUTIL, FOR and CASE present in many high level languages are allowed to include by Pseudo code Difference between Algorithm and Pseudo code As we have described, an algorithm is a set of instructions which provide solution to a specific problem. A Pseudo code, on the other hand is a method used to define an algorithm. An algorithm is written in a natural language while pseudo code can be written in high level programming languages. But not a specified language syntax is used in pseudo code. It, therefore, can be understood by the programmers acquainted with different programming languages. Besides, transformation of an algorithm written in pseudo code to programming code is easier than an algorithm written in natural language.