Page 107 - Trackpad_V4.0_c6_Flpbook
P. 107
Topic Flashback 21 st Century #Critical Thinking
Skills #Technology Literacy
Match the following:
1. Start and Stop a.
2. Decision b.
3. Input and Output c.
4. Flow Line d.
5. Process e.
SOLVING PROBLEMS USING ALGORITHMS AND FLOWCHARTS
Some examples are given below to solve the problems using algorithms and flowcharts:
Example 1: Write an algorithm and draw a flowchart to check whether a given number is even
or odd.
Algorithm: Flowchart:
Step 1: Start.
Start
Step 2: Read Number.
Step 3: Check If Number % 2 == 0 Then Read a Number
print "Number is even."
Else
Is
print "Number is odd." Yes
Number%2==0? Print Number is even
Step 4: Stop.
No
Print Number is odd
Stop
Algorithmic Intelligence 105

