topic badge
CanadaON
Grade 8

11.06 Algorithms in code

Interactive practice questions

Look at the pseudocode below

START
SET a = 73
SET b = 44
SET c = a + b
PRINT c
END

What value is printed at the end of the code?

OUTPUT: $\editable{}$

Easy
< 1min

Look at the pseudocode below

START
SET a = 26
SET b = 11
SET c = a * b
PRINT c
END

What value is printed at the end of the code?

Note: the symbol * represents multiplication.

Easy
< 1min

Look at the pseudocode below

START
SET a = 2
SET b = a * a * a
PRINT b
END

What value is printed at the end of the code?

Note: the symbol * represents multiplication.

Easy
< 1min

Look at the pseudocode below

START
SET a = 1
SET b = 3
SET c = a ^ b
PRINT c
END

What value is printed at the end of the code?

Note: the symbol ^ represents exponentiation.

Easy
< 1min
Sign up to access Practice Questions
Get full access to our content with a Mathspace account

Outcomes

8.C3.1

Solve problems and create computational representations of mathematical situations by writing and executing code, including code that involves the analysis of data in order to inform and communicate decisions.

8.C3.2

Read and alter existing code involving the analysis of data in order to inform and communicate decisions, and describe how changes to the code affect the outcomes and the efficiency of the code.

What is Mathspace

About Mathspace