0% found this document useful (0 votes)
17 views

4th Form Programming Classwork

The document defines key concepts in problem solving and programming including: 1) It defines a problem, problem solving, and a solution. It also outlines the main steps in the problem solving process: define the problem, propose and evaluate solutions, and determine the most efficient solution. 2) It defines the "divide and conquer" method and an algorithm. 3) It explains what IPO stands for in programming: Input, Processing, Output. It describes the purpose of an IPO chart and provides an example chart. 4) It identifies five main data types in programming: integer, real number, character, string, and array.

Uploaded by

Ayo Nelson
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
17 views

4th Form Programming Classwork

The document defines key concepts in problem solving and programming including: 1) It defines a problem, problem solving, and a solution. It also outlines the main steps in the problem solving process: define the problem, propose and evaluate solutions, and determine the most efficient solution. 2) It defines the "divide and conquer" method and an algorithm. 3) It explains what IPO stands for in programming: Input, Processing, Output. It describes the purpose of an IPO chart and provides an example chart. 4) It identifies five main data types in programming: integer, real number, character, string, and array.

Uploaded by

Ayo Nelson
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 4

Ayo Nelson 4m

4th Form Programming Classwork

1. Define a Problem.. (1 marks)

A problem is a situation or question of inquiry that poses some difficulty to overcome

and needs to be dealt with.

2. What is Problem Solving? (2 marks)

Problem solving is the process of finding solutions to difficult or complex issues.

3. Define a Solution. (1 marks)

A solution is a means of solving a problem.

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

problem?’’ are normally asked here.

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

better it will be.

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,

step by step, what you have done.

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

can also involve improving on the solution.

5. (10 marks)

6. What is the divide and conquer method? (2 marks)

The divide and conquer method is essentially dividing a problem into smaller easier tasks

to aid in answering a bigger question (problem decomposition). For example, while

someone is preheating an oven, another person could be greasing a pan.

7. What is an algorithm? (2 marks)

An algorithm is a set of rules or a sequence of precise instructions for solving a problem

in a finite amount of steps.

8. What does IPO stand for? ( 3 marks)

I – input

P- Processing

O – Output

a. What is the purpose of an IPO chart? (2 marks)

The purpose of an IPO chart is to create a formal approach to defining a problem

in a logical way.

b. Draw an IPO chart and put the following steps in the correct columns.

INPUT PROCESSING OUTPUT


Ayo Nelson 4m

Num1 Read three numbers Total

Num2 Add three numbers

Num3 Output the total of

numbers

Regular price of items Discount amount Discounted price

Discount amount = 0.20*

Discounted price =

regular price – discount

amount

i. Num1, read three numbers, num2, add the three numbers, num3, total,

output the total of the numbers. (7 marks)

ii. Regular price of items, discount amount=0.20*regular price, discount

amount, discounted price, discounted price=regular price - discount

amount. (5 marks)

9. What is an identifier? (2 marks)

An identifier is a label or name given to a function that allows an individual using the

computer to run, locate or associate each function.

10. Write a paragraph explaining constants and variables. (3 marks)

A variable is a symbolic name assigned to a memory location that stores a particular

value. Variables are analogous to buckets or envelopes where information can be

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

Real number e.g. 4.78

Character e.g. ‘’A’’ or ‘’t’’

String e.g. ‘’ burger’’

Array e.g. a list of food items

You might also like