Before designing an algorithm it is important to first understand what the problem is. Algorithms can be designed using pseudocode or a flowchart, and the standard notations of each should be known.
An algorithm is a plan, a logical step-by-step process for solving a problem. Algorithms are normally written as a flowchart or in pseudocode.
The key to any problem-solving task is to guide your thought process. The most useful thing to do is keep asking ‘What if we did it this way?’ Exploring different ways of solving a problem can help to find the best way to solve it.
When designing an algorithm, consider if there is more than one way of solving the problem.
When designing an algorithm there are two main areas to look at:
Before an algorithm can be designed, it is important to check that the problem is completely understood. There are a number of basic things to know in order to really understand the problem:
Once these basic things are understood, it is time to design the algorithm.