Definition of Flowchart
Flowchart is the combination of two
words which are ‘Flow’ and ‘Chart’. A charts consists of different symbols
which display the information about any program and Flow indicates the
direction of processing that information which takes place in a program.
Flowchart is
the graphical representation of an algorithm. It indicates a way of visually
presenting the flow of data, operations which are performed on that data and
sequence of these operations. Flowchart is similar as layout plan of a
building. As a designer of buildings draws a layout plan of the building before
constructing it similarly a programmer designs the flowchart of a program
before writing that program. It is designed according to defined rules and
principles.
Symbols of Flowchart
For Input/Output:
Parallelogram
symbol is used to represent an input or output step.
Rectangle
symbol is used to represent a process step in flowchart.
Diamond
symbol is used to represent a selection step. Condition is written in the
diamond and flow of control from diamond symbol may go in two directions. One
direction if the condition is true and one direction if the condition is false.
Start/End:
Oval symbol
is used to represent the start and end step of the flowchart.
|
Flow Lines:
To combine
two or more flow lines circle symbol is used. When two or more symbols come
from different directions and move to one direction then connector (circle) is
used.
To call a
function, rectangle symbol with double lines on left and right is used. The
name of that function which we have to call is written inside the symbol with
their parameters.
This symbol
is used with for loops to specify start and stop conditions.
Guidelines for Drawing Flowchart
1. Guidelines for drawing a good
flowchart are following:
2. Flowchart should be neat and clean
and easy to follow.
3. All requirements should be listed in
a logical order while drawing a flowchart.
4. The usual direction of flowchart is
from top to bottom or from left to right.
5. Only one line should come out from
process symbol.
6. Just one line should enter a decision
symbol and two lines should come out of decision symbol, one for each possible
answer.
7. Just one line is used with oval symbol.
8. Start and end of flow chart must be
logical.
9. Comments should be written in remarks
symbol.
If the flowchart becomes complex then
connector is used to reduce the flow lines.
1. It is useful to check the validity of
flowchart by using the sample data.
Limitations of
Flowchart
Followings are two limitations of flowchart:
1.
To draw flowcharts for complex
problems is difficult.
2.
If any change is required, flowchart
has to be redesigned.
Why we use Flowcharts
1. It is used to develop understanding
that how a process is done.
2. To study a process for improvements.
3. It is used when better communication
is needed between people involved with the same process.
4. When we have to planning a project
5. It is used to document a process.
Examples of Flowchart:
Example 1
Following flow chart represent the steps for adding two
numbers.
The following flowchart represents the steps of an algorithm
that inputs marks of a student. If marks are 40 or more, it display “pass”,
otherwise it display “fails”
Some basic purposes to use flowcharts
are followings:
1. It is used to show the steps of an
algorithm with an easy way.
2. It is used to understand the flow of
the program.
3. Flowchart is used to improve the
logic for solving a problem.
4. Using flowchart program can be viewed
and debugged easily.
5. It is used to represent an algorithm
in simple graphical manners.
No comments:
Post a Comment