0% found this document useful (0 votes)
4 views3 pages

Flowcharts 2

The document provides exercises related to flowcharts, focusing on the use of variables, selection statements, and Boolean logic. It includes tasks such as creating flowcharts for calculating age, averaging numbers, determining pass or fail based on exam scores, and assigning grades based on score ranges. The exercises aim to enhance understanding of flowchart design and decision-making in algorithms.

Uploaded by

sixthbit
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views3 pages

Flowcharts 2

The document provides exercises related to flowcharts, focusing on the use of variables, selection statements, and Boolean logic. It includes tasks such as creating flowcharts for calculating age, averaging numbers, determining pass or fail based on exam scores, and assigning grades based on score ranges. The exercises aim to enhance understanding of flowchart design and decision-making in algorithms.

Uploaded by

sixthbit
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Flowchart Exercises

1. This flowchart uses a variable. A variable is a named storage location


where you can store data. The data value can change in a variable.

a) What is the variable used in this flowchart ?

The flowchart can put data into age, for example:

The data the user enters will be stored in age.


The flowchart can change the data in age, for example:

Above process adds 10 to age and then stores the result.

The flowchart can access the data in age,


for example :

This will output the contents of age.

b) What will be the output if you put your age into this flowchart ?

2. Draw a flowchart that asks user to enter 3 numbers, then it should calculate the average of
that 3 number and output the result.

Selection statements

A selection statement is used when decision needs to be made in an algorithm. It has a condition.
This is a statement that will be either true or false.
Example :

Boolean logic
The conditions in the flowchart above can only be answered by True
False. These are called Boolean conditions. Boolean means that there are
only two options. These could be:

True/ False
Yes/ No
l/0
Positive/ Negative

There is no ‘maybe’ answer.

Comparison operators
Exercise

3) Draw a flowchart that takes student’s exam score as the input and finds out if the student is pass
or fail. The pass mark is 55.

4) Draw a flowchart that takes student’s exam score as the input and outputs his grade.
75 and above = A grade
50 to 74 = B grade
30 to 49 = C grade
below 49 = F grade

You might also like