Chap2 - 2.1 Understand Problem Solving Concept
Chap2 - 2.1 Understand Problem Solving Concept
Chap2 - 2.1 Understand Problem Solving Concept
PROBLEM SOLVING
AND PROGRAM
DESIGN
CHAPTER 2.0
PROBLEM SOLVING METHODS
1
COURSE LEARNING OUTCOME (CLO):
Upon completion of this course, students should be able to:
2
SPECIFIC OUTCOME:
2. 1 Demonstrate the understanding of
Programming Life Cycle
2.2 Understand problem solving concept
2.3 Apply the different types and patterns
algorithm to solve problem.
3
2.1 UNDERSTAND PROBLEM SOLVING
CONCEPT
4
PROBLEM SOLVING CONCEPT
Identifying the problem--Which problem should I address? If
there are several, how do I choose the most important one?
Describing the problem--How do I accurately and completely
describe the problem?
Analyzing the problem--What are the different causes of the
problem, and which causes are most important to solve right
away?
Planning the solutions--What are the different alternative
solutions for solving the problem?
Implementing the solutions--How do I make sure the
solutions are implemented correctly and effectively?
Monitoring/evaluating the solutions--How did the solutions
work? What needs to be changed? 5
Define Input, Process
And Output
DEVELOPING THE INPUT PROCESS OUTPUT
(IPO) CHART
Extends and organizes the information in the
Problem Analysis Chart.
It shows in more detail what data items are input,
what are the processing or modules on that data,
and what will be the result or output.
Problem
Write a Input Process Output (IPO) to find an area
of a circle where area = pi * radius * radius
8
STEPS OF PROGRAM EXECUTION
Input – Refers to the process of entering data, program and
instructions into the computer system using input devices.
Process – Computer processes raw data into usable
information to be used by user. Data processing is done by the
CPU (Central Processing Unit).
Output – Output is raw data that has been processed by the
computer (result). Output will be converted to an
understandable form before being displayed or printed.
9
EXAMPLE: FLOW OF ATM PROGRAM
• Assume that our transaction is money withdrawal.
The instructions are:
a. Get the card number from the user (Input)
b. Get pin number from the user (Input)
c. Process the input data (Process)
d. Get the transaction chosen by the user (Input)
e. Get the account type from the user (Input)
f. Process the transaction as wanted by the user (Process)
g. Withdraw amount of money required by the user(Output
h. Print receipt for the user (Output)
10
INPUT PROCESS OUTPUT
• First step:
– Data entered by user are stored in memory (input).
• Second step:
– CPU will instruct program to process the card number and
ATM pin number with the data in memory concurrently.
Program will execute the transaction chosen by the user and
store the result in memory.
13
• Third step:
– The outputs are money withdrawal and receipt (output).
ACTIVITY 1: FIRE SIDE CHAT
1. Build a group in 3
2. Recall what you have learn in chapter 1 and
chapter 2 (2.1)
3. Write down 3 things that you have learned in
class (only 3 parts)- 3 minutes
4. Move to your friends in class and share the
answer (1 friend=1 aswer)
5. Move again to other friends and share the answer
until you fullfill 7 parts of TREE GRAPHIC
6. I will call 3 people to share the answer
14
DISCUSS
15
16