Difference b/w Flowchart and Algorithm:
Flowchart:
- Standard symbols are used to design flowchart.
- Flowchart is more time-consuming.
- It is difficult to modify.
- It is a graphical representation of solution.
Algorithm:
- Simple English is used to write algorithm.
- Algorithm is less time-consuming.
- It is easier to modify.
- It is a step-by-step procedure to solve a problem.
Example 1:
Algorithm of sum of 2 numbers :
Start
Input 1st number
Input 2nd number
Total = 1st number + 2nd number
Display Total
- Exit
Example 2:
Algorithm to calculate a the area of circle :
- Start
2. Input radius
3. area = 3.14*radius*radius
4. Print area
5. Exit
No comments:
Post a Comment