You are on page 1of 4

Sean Andrei G.

Calip

1. Ask the user to enter two integer values. Then, get and display the 20% of the product of two
input numbers

Pseudocode

Start

Input Int1, Int2

Product = Int1*Int2

Result = Product*0.2

Print result

Stop

Flowchart

Start

Int1,Int2

Product = Int1*Int2

Result = Product*0.2

Print result

End
Sean Andrei G. Calip

2. Ask the user to input his/her height and weight. Then, compute his/her body mass index (BMI).
Display if the user is normal, overweight, or underweight.

Pseudocode

Start
Input Weight,Height
BMI = Weight / (Height)^2
If BMI = <18.5, Print Underweight
If else, BMI = <24.9, Print Normal
Else, Print Overweight
End

Flowchart

Start

Weight,Height

BMI = Weight / (Height)^2

YES
BMI < 18.5 Print Underweight

NO

YES
BMI < 18.5 Print Normal

NO

Display the result

End
Sean Andrei G. Calip

3. Find the sum of the numbers in each set. You are given hundred numbers divided in ten sets in
the following order.

Set 1: 1-10
Set 2: 11-20

Set 10: 91-100

Pseudocode

Start
Input count = 1 and a = 1
If a is <= 10
If Yes then set sum = 0 and b = 1
Else stop
Input set sum = 0 and b = 1
If b is <= 10
If yes then sum = sum + count, count = count + 1, b = b + 1
Else print sum
Input sum = sum + count, count = count + 1, b = b + 1
If b is <= 10
If yes then sum = sum + count, count = count + 1, b = b + 1
Else print sum
Input a = a + 1
If Yes then set sum = 0 and b = 1
Stop
Sean Andrei G. Calip

Flowchart

Start

count = 1 a=1

NO
End Is a <= 10? a=a+1

YES

sum = 0 b=1 Print sum

NO
Is b <= 10?

YES

sum = sum + count


count = count + 1
b=b+1

You might also like