An algorithm is a sequence of steps carried out in a certain order for solving a certain problem. There may be more than one way of solving the problem, of which an algorithm may be one. Not all problems can be solved by using an algorithm.

For example, we want to solve the quadratic equation

We could use the quadraticformulaIn this caseso Henceor

The above solution however was not obtained by the use of an algorithm. If we wanted to use an algorithm to solve the equation we could complete the square and makethe subject.

We can start by factorising with 3.

Use the identityNow write

We can collect the last two termsso

Now make x the subject. Add 13 over 36 to both sides.

Square root both sides, remembering that there are two square roots, one + and one -.

Subtractfrom both sides.

Both methods give the same answer, but only the second method is the result of an algorithm.