0% found this document useful (0 votes)
24 views9 pages

Ict Rev

The document contains 5 examples of coding problems and their pseudocode solutions: 1) Finding the total and average of 3 marks. 2) Calculating the area of a circle. 3) Converting temperature from Celsius to Fahrenheit. 4) Finding the bigger of two numbers. 5) Calculating the area of a rectangle. For each problem, the pseudocode includes input/output statements, variable declarations, and logical/mathematical operations to programmatically solve the given task.

Uploaded by

Farfi Uddin
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)
24 views9 pages

Ict Rev

The document contains 5 examples of coding problems and their pseudocode solutions: 1) Finding the total and average of 3 marks. 2) Calculating the area of a circle. 3) Converting temperature from Celsius to Fahrenheit. 4) Finding the bigger of two numbers. 5) Calculating the area of a rectangle. For each problem, the pseudocode includes input/output statements, variable declarations, and logical/mathematical operations to programmatically solve the given task.

Uploaded by

Farfi Uddin
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/ 9

1. Find the total and average for three marks.

FLOWCHART :

STOP
PSEUDOCODE :

BEGIN

DECLARE m1, m2, m3, total : INTEGER


DECLARE avg : DOUBLE

OUTPUT “enter any three marks”


INPUT m1, m2, m3

total m1 + m2 + m3
avg total/3

OUTPUT “total marks:”, total


OUTPUT “average marks:”, avg

END

PYTHON :

2. Calculate the area of the circle.

FLOWCHART :

START

Input radius

Area = (22/7)*radius*radius

Output Area

STOP
PSEUDOCODE :

BEGIN

DECLARE radius, area : DOUBLE

OUPUT “enter radius”


INPUT radius

Area (22/7)*radius*radius

OUTPUT “Area of Circle:”, Area

END

PYTHON :

3. Converting temperature from Celsius to Fahrenheit. FLOWCHART :


Stop

PSEUDOCODE :

BEGIN

DECLARE tempC, tempF : DOUBLE

OUTPUT “enter temperature in Celsius”


INPUT tempC

tempF tempC * 9/5 + 32

OUTPUT “temperature in Fahrenheit:”, tempF

END

PYTHON :

4. Find the bigger of two numbers. FLOWCHART :


PSEUDOCODE :

BEGIN

DECLARE num1, num2 : INTEGER

OUTPUT “enter first number”


INPUT num1

OUTPUT “enter second number”


INPUT num2

IF num1 > num2 THEN

OUTPUT “first number is bigger than second number”

ELSE

OUTPUT “second number bigger than first number”

END IF

END

PYTHON :

5. The area of a rectangle.

PSEUDOCODE :

BEGIN

DECLARE length, width, area : DOUBLE

OUPUT “enter length”


INPUT length

OUTPUT “enter width”


INPUT width

area length*width

OUTPUT “the area of the rectangle is:”, area

END
FLOWCHART :

PYTHON :

You might also like