What is an algorithm ?

November 15, 2021 Posted by Pasindu Sathsara

    What is an algorithm ?


  •  An algorithm is a set of step by step instructions for solving a problem to achieve a result.  
  • Set of rules to be followed in solving problem.
  • Algorithm is step by step procedure  which defines set of instruction to be executed in a certain order to get desired output.
  • Sequence of computational   steps that transform the input into the output. 
  • Algorithm can perform calculation, data processing and automated reasoning tasks. 
  • Algorithm can be implemented in more than one language. 
Example :-

     We can describe how to make a instant noodles ?

  • First you have to boil water an then put the noodles in boil water. 
  • Then after few miniates add ingredients and other related packets in the noodles packet. 
  • Next put that noodles to the plate and make attractive noodles dish.   
  • Then serve it. 

To make the instructions clear and ambiguous we can draw a chart the same sequence of steps in what is given below.  


 There are five main important characteristic of an algorithm as stated below. 

  • An algorithm is well ordered. 
  • An algorithm has ambiguous operations. 
  • An algorithm has effectively computable operations.
  • An algorithm produces a results. 
  • An algorithm halts in a finite amount of time.