Flowchart Algorithm
Flowchart Algorithm
are:
1. Algorithms 2. Flow charts
logical procedure for solving a problem. Algorithm will start with the term start and terminate with stop statement. For each and every step we provide a step number. Some basic terms implemented in an algorithm:
1. Start : The indication of this term is starting point of an algorithm. 2. Let : The purpose of this command is assigning a value or for
calculation.
3. Print : It will display the message or a value. 4. Read : To collect the value into a respective name Read is suitable. 5. Stop : The termination of the algorithm is possible with the term Stop (or) End.
Step 1 : start
Step 2 : let a = 5 Step 3 : let cube = a x a x a
3. Design an algorithm to calculate area and perimeter of a rectangle. Step 1 : start Step 2 : read l Step 3 : read b Step 4 : let area = l x b Step 5 : let per = 2 x ( l + b ) Step 6 : print area Step 7 : print per Step 8 : stop (or) Step 1 : start Step 2 : read l , b Step 3 : let area = l x b Step 4 : let per = 2 x ( l + b ) Step 5 : print area , per Step 6 : stop
Properties of an algorithm :
5. Input / Output : Each algorithm must take zero, one or more quantities
as input data and produce one or more output values.
Exercise
Flow Chart :
3. Flow chart should be verified for its validity with some test
data.
Following are the standard symbols used in drawing flowcharts : Symbol Name Vowel Rectangle Operation Start / stop Processing
Parallelogram
Circle Rhombus Arrows
Input / Output
Used to connect different parts of flow chart (connector) Decision making or condition Flow
Start
Let c = 5
Let cube = c x c x c
Print cube
Stop
Exercise :
THANK YOU.