You are on page 1of 67

Flowcharting

(Flowcharting)
(Flowchart) (Image)
(Symbol)
(Algorithm)

(Flowcharting)


(1/3)
3

10

10

10

10

3
?

(2/3)

(3/3)



5

5 - 7 1
8 - 14 2
15 3

15


2

(System flowchart)

(Program flowchart)

(System flowchart)










100

100

(Program flowchart)




100

0.5 * *

100

100

0.5 * *

100

(1/2)
(Flexible Language)


(Step Flowing)


(Easy to Debug)

(2/2)
(Easy to Read)


(Problem Define)


(1/13)




American National
Standard Institute (ANSI) International Standard
Organization (ISO)

(2/13)

(Terminal)



(Input/output)


START
STOP

read name

display area

1.

2.
1.
2.


name

area

(3/13)


1. A + B

C=A+B
C
(Process)
Sum = 0

(Compare /
Decision)

i <= 10
true

false

2.

sum
0

i
10
- i


-

(4/13)

print A
(Document)

(Display)

A, B

display A , B

(5/13)

(Comment)

(Manual Input)


read A

read A

A = Age

(6/13)


i

1 1

for i =1 to 100
100
(Preparation)
sum = sum + i

(Flow line)


sum i

(7/13)



(In-Page
connector)


(Off-Page
Connector)


write A
A

A=3
1

A

A

A
3
1

(8/13)

read A

punch B , C
(Punch card)

(Card Desk)

punch
bi b=1 ,
n

1.

A
1

2. B,C
1
B1 , B2 , Bn
n

(9/13)


read ID ,
name

(Punched tape)



(Magnatic tape)

ID , name

(10/13)



(Magnatic disk)



(Magnatic drum)

(11/13)



(Predefine Process)

(Offline Processing)


findGrade


findGrade

(12/13)

(Auxiliary Operation)



(Sorting)

(13/13)

(Communication
Link)

(1/3)




START


read age
age > 60
true
You are old

STOP

false

(2/3)

START

sum = 0
i = 1 to 10

sum = sum + i
i
sum
STOP

(3/3)



(1/3)
(Sequence)


(2/3)

(Selection/Decision/Condition)

2

(3/3)
(Iteration / Loop)


2


(1/3)


1

(2/3)
START

A=5

A 5

B=3

B 3

C=A+B

print C
STOP

A B C
C

(3/3)
START

A,B
C=A+B

print C
STOP

A, B

A B C
C




2.5 /1
1.

2.
--> < >
--> < >
---------------------------------------------------- : < >
: < >


3.

4.

Last_meter
Curr_meter
Num_meter
Electric_fee


5.
1.
2.
3.
4.
5.
6.


last_meter curr_meter
num_meter = curr_meter last_meter
electric_fee = num_meter * 2.5
num_meter , electric_fee

Flow chart
START

Last_meter ,
Curr_meter

Num_meter = Curr_meter Last_meter

Electric_fee = Num_meter * 2.5

Num_meter , Electric_fee

STOP







(IF - THEN)
(IF THEN - ELSE)
(IF THEN ELSE IF | CASE)

(1/5)

(2/5)

START

age

read age
age > 60
true
You are old

STOP

false

age 60

You are old


(3/5)


GoodLuck
Welcome
Manager Exit
Password System

ans
ans = GoodLuck

Welcome
Manager

Exit Password
System

(4/5)

5000 10%
3

1. .
2.
- 5000 = + ( * 10/100)

3. = * 3
4.
5.

(5/5)
A

START

read
name ,salary

salary < 5000

bonus = salary * 3

false

Name , salary ,
bonus

true
salary = salary + (salary*10/100)

STOP


IF THEN

IF THEN
BEGIN
1 ;
2 ;
END;

IF THEN
1

ELSE
BEGIN
1 ;
2 ;
END;

(1/6)

(2/6)
False

Female = Female + 1

Sex = 1

True

Male = Male +1

sex =1

Male 1
sex =1

Female 1

(3/6)

START

age

read age
false

age > 60

You are young

true

You are old

STOP

age 60
You are old
You are young

(4/6)

Do you like Pascal

ans

ans = y OR ans=Y

Im sorry to hear that

Do you like Pascal


ans

ans y Y

Thank You

Good Bye

-
Thank you
-
Im sorry to hear that

Goodbye

(5/6)

5000 10% 5000 5%
3

1. .
2. < 5000
- = 10/100
- = 5/100

3. = + ( * )
4. = * 3
5.
6.

(6/6)
A

START

read
name ,salary
false

salary < 5000

rate = 5 / 100

salary = salary+(salary * rate)

true
rate = 10 / 100

bonus = salary * 3

Name , salary ,
bonus
STOP

( IF)


2
False
False
4

False

True

True

True

( IF)
Score = mid + final
false
false
false
false

Grade = F

Score >=50

Score >=60

true

Grade = D

Score >=70

true

Grade = C

Score >=80

true

Grade = B

true

Grade = A

( CASE)
2

( CASE)
Score = mid + final

score

80..100

Grade = A

70..79

Grade = B

60..69

Grade = C

50..59

Grade = D

0..49

Grade = F


(Controlled Loop)
(Pre-Test Condition)
(Post-Test Condition)

Next


N 1 1 5
Next
N
For N =1 , 5

Print N
Next


True
1

False


N <= 5

N=1

N
N 1 (N=N+1)
N <=5

True

Print N

N = N+1

False

2
False


True


N
N 1

N >
5

N=1

Print N

N = N+1
False

N>5
True

You might also like