Download presentation
Presentation is loading. Please wait.
Published byAnnice Glenn Modified over 6 years ago
1
Flow Charts Basic Flow Chart Symbols Few sample flowcharts Rules
Description of each symbols Few sample flowcharts Rules An example
2
Basic Flow Chart Symbol
Terminal Input/Output Processing Decision Flow lines Connectors
3
Terminal The terminal symbol is used to indicate the beginning (start ), end ( stop), and pauses ( Half) in the program logic flow . A pause is normally used in the program logic under some error conditions, or if forms had to be changed in the computer’s line printer during the processing of that program.
4
Input/Output The input / output symbol is used to denote any function of an input / output device in the program. If there is a program instruction to input data from a disk, tape ,terminal, or any other type of input device , that step will be indicated in the flowchart with an input / output symbol similarly, all output instruction whether it is output on a printer, magnetic tape, magnetic disk, terminal screen, or any output device, are indicated in the flowchart with an input / output symbol.
5
Processing A processing symbol is used in a flowchart to represent arithmetic and data movement instruction. Hence, all arithmetic processes of adding subtracting , multiplying and dividing are shown by a processing symbol. . The logical process of moving data from one location of the main memory to another is also denoted by this symbol . When more than one arithmetic and data movement instructions are to be executed consecutively, they are normally placed in the same processing box and they are assumed to be executed in the order of their appearance .
6
Decision The decision symbol is used in a flowchart to indicate a point at which a decision has to be made, and a branch to one of two or more alternative points is possible. Figure 11.2 (see book) shows three different ways in which a decision symbol can be used. It may be noted from these examples that the criterion for making the decision should be indicated clearly within the decision box. Moreover, the condition upon which each of the possible exit paths will be executed should be unidentified, and all the possible paths should be accounted for. During execution, the appropriate path is followed depending upon the result of the decision.
7
Flow Lines Flow lines with arrowheads are used to indicated the flow of operation, that is, the exact sequence in which the instructions are to be executed. The normal flow of flowchart is from top to bottom and left to right. Arrowheads are required only when the normal top to flow is not to be followed. However, as a good practice, and to avoid ambiguity, flow lines are usually drawn with an arrowhead at the point of entry to a symbol. Good practice also dictates that flow lines should not cross each other, and that such intersections should be avoided whenever possible.
8
Connectors Whenever a flowchart becomes complex enough that the number and direction of flow lines is confusing , or it spreads over more than one page, it is useful to utilize the connector symbol as a substitute for flow lines. This symbol represents an entry from, or an exit to another part of the flowchart. A connector symbol is represented by a circle, and a letter or digit is placed within the circle to indicate the link.
9
How to draw Flow Chart?
12
Flow Chart Rules Some of the rules and guide lines are as follows:
First chart the main line of logic Then incorporate detail. Maintain a consistent level of detail for a given flowchart. Do not chart every details; otherwise, the flowchart will only be a graphic representation of the program. Details in the flowchart should be easy for anyone to understand.
13
An example Example: A student appears in an examination, which consists of total 10 subjects, each subjects having maximums marks of 100. The roll number of the student, his/her name, and the marks obtained by him/her in various subjects, are supplied as input data. Such a collection of related data items, which is treated as a unit, is known as a record. Draw a flowchart for the algorithm to calculate the percentage marks obtained by the student in this examination, and to print it along with his/her roll number and name.
14
Solution Start Read input data Add marks of all Subjects Giving total
Write output Percentage = Total/10 Stop
Similar presentations
© 2024 SlidePlayer.com Inc.
All rights reserved.