Page 433 - Cs_withBlue_J_C11_Flipbook
P. 433

14                        IMPLEMENTATION OF


                                                                    ALGORITHMS TO SOLVE

                                                                                 PROBLEMS













                          Learning Objectives


 14.1  Concept of Recursion      14.2  Types of Recursion  14.1  Algorithm      14.2  Pseudocodes and Flowcharts
 14.3  Simple Recursive Methods  14.3  Computational Complexity and Big O Notation   14.4  Properties of Writing a Good Algorithm
                     14.5  Some Standard Algorithms



                 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 result. After repeated review we finalise our plan and work accordingly. While developing a software we follow
                 the same procedure. The steps to be followed are written in details sequentially in simple English. The diagrammatic
                 representation of the steps are also done. When the developers are satisfied that the steps will yield the necessary
                 result, corresponding coding in high level language is done. Algorithm, Pseudo codes, Flowchart are all are different
                 techniques which help us in planning a software.
                 Say we want to plant a tree. Then, there are some crucial steps that we
                 have to follow. Let us document them one after the other.            #Environmental Awareness
                 1.  Choose the right tree that you want to plant. Right tree means the
                   species and full-grown size of the tree is best suited for your place.
                 2.  Choose the right place to plant the tree. Right place means the tree has
                   enough space to grow without affecting with surrounding infrastructure or
                   underground pipes.
                 3.  Once you select the right tree and place, collect equipment to dig a planting
                   hole. Ensure that the planting hole should be three times wider than the
                   current root mass but should not deeper than the root ball.
                 4.  Soften backfill soil as much as possible.
                 5.  Fill the 10 to 20 percent area of the planting hole with compost.
                 6.  Place the plant in the hole.
                 7.  Cover the roots with soil.
                 8.  Gently pack the soil around the tree.
                 9.  Water the plant regularly to provide suitable growth to the plant.
                 Similarly, for any problem solving be it our day-to-day work, or any mathematical or computational problem, we need
                 to follow a set of steps in a proper sequence, to achieve our desired goal. In mathematics and computer science, this
                 process of listing instructions step-wise is called an Algorithm.



                                                                                                                       431
                                                                            Implementation of Algorithms to Solve Problems  431
   428   429   430   431   432   433   434   435   436   437   438