Page 102 - Computer science 868 Class 12
P. 102
03 IMPLEMENTATION OF
ALGORITHMS TO SOLVE
PROBLEMS
Learning Objectives
3.1 Introduction 3.2 Algorithm
3.3 Pseudocodes and Flowcharts 3.4 Computational Complexity and Big O Notation
3.5 Some Standard Algorithms
3.1 INTRODUCTION
We follow a set of instructions to accomplish any task. In our daily life, to accomplish any task systematically, it’s planning
must be full proof. This can be done by writing down the steps we need to follow in a sequential manner. We can make
modifications if we feel that these changes will yield better results. After repeated review, we finalise our plan and
work accordingly. While developing software we follow the same procedure. The steps to be followed are written in
detail sequentially in simple English. The diagrammatic representation of the steps is also done. When the developers
are satisfied that the steps will yield the necessary result, the corresponding coding in the high-level language is done.
Algorithms, Pseudo codes, and Flowcharts are all different techniques that help us in planning software.
3.2 ALGORITHM
Let us take a real-life example. Say, we want to make a cup of tea. Let us document the steps one after the other.
Step 1: Start.
Step 2: Measure one cup of water.
Step 3: Pour the water into a saucepan.
Step 4: Switch on the gas.
Step 5: Keep the saucepan on the gas.
Step 6: Repeat step 7 until the water starts to boil.
Step 7: Heat it for one minute.
Step 8: Add 1 teaspoon tea leaves and pour one cup of milk into the saucepan.
Step 9: Add two teaspoons of sugar to the solution.
Step 10: Boil it for two minutes.
Step 11: Strain the tea into a cup.
Step 12: Stop.
100100 Touchpad Computer Science-XII

