4th Form Programming Classwork
4th Form Programming Classwork
4. Outline and explain the steps in the Problem Solving process. (No less than 2 sentences)
Define the problem – one must first define or understand what the problem is in order to
make further progress. Questions such as ‘’what’s going on?’’ or the obvious ‘’what’s the
Propose and evaluate solutions – This step includes investigation, research and
analyzation of data that you gathered while trying to come up with a solution. It normally
requires someone to come up with more than one ways to solve a problem in order to
have a greater selection to choose from for the next step. The more solutions found the
Determine the most efficient solution – After coming up with the solutions, one should
try to find the most efficient one, or the one that is the most effective. This selection will
be is essential to the speed or accuracy in which a task is done. While selecting the best
solution, questions like ‘’what’s the best thing to do’’ should be asked to keep on the
right track.
Ayo Nelson 4m
Develop the algorithm – a set of rules for solving your problem should be developed, or
an algorithm. ‘’How did I get to the solution?’’ should be asked here, in order to track,
Test and validate the solution – your solution has to be tested to see if it really works.
‘’Have we solved the problem?’’. Trying to re solve the problem is a good idea. This step
5. (10 marks)
The divide and conquer method is essentially dividing a problem into smaller easier tasks
I – input
P- Processing
O – Output
in a logical way.
b. Draw an IPO chart and put the following steps in the correct columns.
numbers
Discounted price =
amount
i. Num1, read three numbers, num2, add the three numbers, num3, total,
amount. (5 marks)
An identifier is a label or name given to a function that allows an individual using the
maintained and referenced. When referring to variables we use the name of the variables,
not the data stored inside of it. A constant is a piece of data that has a set value, or a
Ayo Nelson 4m
variable whose value does not change its value in the program. For example in the
statement ‘pass mark = 60’, pass mark is a constant since the pass mark cannot change
from 60.
11. Identify the 5 different data types and give examples of each. (10 marks)
Integer e.g. -5