Algorithm and Flowchart CV
Algorithm and Flowchart CV
• Definition
-> Finite set of sequential instructions to
accomplish a task
-> step by step solution of the problem
• Characteristics of Algorithm
1. Finiteness
2. Definiteness
3. Effectiveness
4. Input and Output
• Advantages
– Easy to write
– Easy to understand logic
– Easy to identify mistakes
• Disadvantages
– Time consuming
– Difficult to show branching and looping
– Difficult for complex task
Example:
Aim= Algorithm to add two
numbers Input= two numbers
output= Addition of numbers
Step 1: Take two numbers as input
Step 2: Add those two numbers
Step 3: Print the result of
addition
Exercise:
1. Algorithm to calculate area of
rectangle
2. For finding maximum of two number
3. For finding average and sum of given
Flowchart
• Graphical representation of sequence of
instructions to accomplish a
task
/output
FLOW CHART
Example: Flow Chart to add two numbers
Examples of Flow Chart
• Example 1 – Draw a flow chart to find area
of the rectangle