Flowcharting Examples: Example 1: Draw A Flowchart To Convert The Length in Feet To
Flowcharting Examples: Example 1: Draw A Flowchart To Convert The Length in Feet To
Flowcharting Examples
Solution:
START
Input Lft
Lcm = Lft x 30
Print Lcm
STOP
1
Flowcharting Examples
Solution:
START
Input
W, L
A=LxW
Print
A
STOP
2
Flowcharting Examples
Solution:
START
Input
VALUE1, VALUE2
Yes No
Value1 >
Value
Print
“The largest value is”,
MAX
STOP
3
Flowcharting Examples
Flowchart:
START
Base=2
Product = Base
Print Product
STOP
This program can be generalized and solved using the loop as in the
following example
4
Flowcharting Examples
Flowchart:
START
Base =2
Power =4
Product = Base
Counter = 1
is N
Counter < Power
Y Print
Product = Product * Base
Product
5
Flowcharting Examples
Trace table:-
6
Flowcharting Examples
Solution:
Start
C=A+B
Display
Summation (C)
End
7
Flowcharting Examples
Solution:
Start
Data input
(num1 = 7)
num2 = - num1
Display num2
End
8
Flowcharting Examples
Solution:
9
Flowcharting Examples
Solution:
Start
Read N
Yes No
Is N<0
End
10
Flowcharting Examples
Solution:
Start
Input the
variables a,b,c
Is
D≥ 0
real=(-b)/(2*a) root1=(-b+√D)/(2*a)
imag=(√-D)/(2*a) root2=(-b-√D)/(2*a)
root1=real+j*imag
root2=real-j*imag
print
root1, root2
End
11
Flowcharting Examples
Solution:
Start
Angle = 0 Deg.
Display the
Increase Angle
Angle sine
by 10 Deg.
Yes
Is Angle< 360?
No
End
12
Flowcharting Examples
Solution:
Start
Mul = 1
Index = 20
Yes
Is Index>1?
No
Display Mul
End
13
Flowcharting Examples
Solution:
Start
Sum=0
Count=1
No Is Count Yes
even
Sum=Sum+Count
Count=Count+1
No
Is Count>20
Yes
Print Sum
End
14
Flowcharting Examples
Solution:
Start
i=1
Largest=a(1)
i=i+1
Yes
Is i>n
No Print
Largest
15
Flowcharting Examples
Mark Grade
<= 85 Excellent
<=75>85 Very Good
<=65>75 Good
<=50>65 Pass
>50 Fail
Solution:
16
Flowcharting Examples
Start
Input N
K= 1
Yes
Fail Average< 50
No
Yes
Pass Average< 65
No
Yes
Good Average< 75
No
Yes
Very Good Average< 85
No
Excellent
K=K+1
No
K > N
Yes
Stop
17
Flowcharting Examples
Flowchart:
Start
Input N
K=1
Jn=0 &Jp=0
Sumn=0 &Sump=0
Input Num
Yes No
Num< 0
Jn = Jn + 1 Jp = Jp + 1
Sumn = Sumn + Num Sump = Sump + Num
K = K+1
No
K>N
Yes
Stop
18