Computer
Programming I
Compiled by:
Mary Ann B. Taduyo
Learning Outcome
Define the basic flowcharting techniques and
use them in the development of program
flowchart.
Construct flowcharts to express algorithm
Describe and understand the flowchart
symbols.
Flowcharting
Program Design Tools:
Flowchart
Flowchart is a diagram which visually
presents the flow of data through processing
systems.
Algorithms are nothing but sequence of steps
for solving problems..
Program Design Tools:
Flowchart
A flowchart, will describe the operations (and
in what sequence) are required to solve a
given problem.
Flowcharting
Flowchart Symbols
Terminal,
Process,
Input/Output,
Decision,
Connector and
Predefined Process.
Flowchart Symbols
Flowcharting Symbols
Input/Output Parallelogram
• It represents an instruction to an input or an output
device.
Process Rectangle
• This symbol is used to represent a group of
program instructions that perform a processing
function of the program
Flowcharting Symbols
Decision Diamond
• It denotes a point in the program where more
than one path can be taken.
Flowcharting Symbols
Preparation
Hexagon
• This symbols used to represent an
instruction or group in instructions that will
alter, or modify a program’s course of
execution.
Flowcharting Symbols
Start/Stop Oval
• It is used to designated the beginning and the
end of a program, or a point of interruptions.
Connector
• This is a nonprocessing symbols which is used to
connect one part of a flowchart to another without
drawing flow lines
Flowcharting Symbols
Arrowheads
• Used to show the direction of processing or
data flow.
Flowcharting Symbols
Horizontal/
Vertical Lines
• It is used to show reading order or sequence
in which flowchart symbols are to be read.
Flowchart Symbols
Input/Output Start/Stop
Process
Connector
Flow Lines
Decision
Flow Direction
Preparation Indicators
Flowcharting
General Rules for flowcharting
1. All boxes of the flowchart are connected with
Arrows.
2. Flowchart symbols have an entry point on the
top of the symbol with no other entry points. The
exit point for all flowchart symbols is on the
bottom except for the Decision symbol.
Flowcharting
General Rules for flowcharting
3. The Decision symbol has two exit points
4. Generally, a flowchart will flow from top to bottom.
However, an upward flow can be shown as long as
it does not exceed 3 symbols.
Flowcharting
General Rules for flowcharting
5. Connectors are used to connect breaks in the
flowchart.
Examples are:
• From one page to another page.
• From the bottom of the page to the top of
the same page.
• An upward flow of more than 3 symbols
Flowcharting
General Rules for flowcharting
6. Subroutines and Interrupt programs have their
own and independent flowcharts.
7. All flow charts start with a Terminal or Predefined
Process
8. All flowcharts end with a terminal or a contentious
loop.
Examples of
Flowchart
Flowchart – sequential type
Problem 1:
Find the area of circle of
radius (r).
Flowchart – sequential type
Problem 1: Find the area of circle of radius (r).
Start
Read r
Area = Pi * R * R
Print Area
END
Flowchart – sequential type
Problem 2:
Convert temperature
Fahrenheit (F) to Celsius (C)
Flowchart – sequential type
Problem 2: Convert temperature Fahrenheit (F) to
Celsius (c).
Flowchart – sequential type
Problem 3:
Flowchart for an
algorithm which gets two
numbers and prints sum of
their value
Flowchart – sequential type
=
Problem 3: Flowchart for an algorithm which gets two numbers and
prints sum of their value. Start
Read A, B
SUM = A + B
Print SUM
END
Be Ready for Guided
Exercises in Flowcharting
Guided Exercises 3
1. Given the three numbers A, B, C. Draw a
flowchart to compute and print out the sum, the
average, and the product of these values.
2. Write an algorithm that will input the value of
money in Peso denomination and output its
equivalent in Dollars.
Conversion factor: 1 dollar = 49.59 peso.
Thank you and Happy
Day Everyone