wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Coding Fundamentals Review

Total questions: 38

Worksheet time: 21mins

Name
Class
Date
1.

What’s an algorithm?

a)

The word used to describe all computer codes

b)

Sets of instructions to a computer

c)

A type of hardware used with micro:bit

d)

The area of a MakeCode project that shows how a program looks when run on the micro:bit

2.

What is pseudocode?

a)

The coding blocks in MakeCode

b)

A detailed step-by-step plan for your program

c)

A coding language

d)

A computer program

3.

What is an event in programming?

a)

A function that runs automatically

b)

An action that causes something to happen

c)

A type of variable

d)

A loop in a program

4.

What’s the difference between a constant and a variable?

a)

A constant changes, a variable does not

b)

A constant is a type of loop, a variable is not

c)

A constant does not change, a variable can change

d)

A constant is a function, a variable is not

5.

Which of the following is not a type of variable that we talked about in class?

a)

String

b)

Number

c)

Boolean

d)

iteration

6.

Which of the following is an example of a string variable?

a)

day of the week

b)

temperature

c)

is it snowing

d)

Pi

7.

Which of the following is an example of a number variable?

a)

weather condition

b)

temperature (degrees)

c)

is it Sunday

d)

5

8.

Which of the following is an example of a boolean variable?

a)

month

b)

9

c)

is it raining?

d)

students enrolled

9.

In coding, conditionals tell a computer to do which of the following?

a)

How to do it

b)

To do it faster

c)

When to do it

d)

Where to do it

10.

What is the x and y coordinate location of the LED sprite?

a)

4,4

b)

3,4

c)

3,3

d)

4,3

11.

How could you rewrite this pseudocode with loops? Step forward Turn left Step forward Turn left Step forward Turn left Step forward Turn left

a)

repeat 4 time:

[step forward,

turn left]

b)

step forward

repeat 4 time:

turn left

c)

While x <6:

[step forward,

turn left]

d)

repeat 2 times

[step forward,

turn left]

12.

What type of variable is the (x,y) coordinate?

a)

Sprite

b)

Number

c)

String

d)

Boolean

13.

What is pseudocode?

a)

The coding blocks in MakeCode

b)

A way of writing algorithms that uses plain English text

c)

A coding language

d)

A type of hardware used with micro:bit

14.

Information with values that do not change during a program is known as a _______.

a)

Constant

b)

Variable

c)

Derivative

d)

Boolean

15.

Information with values that can change during a program is known as a _______.

a)

Constant

b)

Variable

c)

Derivative

d)

Boolean

16.

True or False: A conditional statement must have all the following: If, then, else, else if.

a)

True

b)

False

17.

What's another word for iteration?

a)

Condition

b)

Input

c)

Repeat

d)

Processing

18.

_______ is a rule or criteria that must be met for an action to be carried out.

a)

Iteration

b)

Conditional statement

c)

Variable

d)

Function

19.

Which of the following is not a way that loops are beneficial when coding?

a)

Saves time

b)

Fewer lines of code to debug

c)

Shorter programs

d)

Removes the need to use variables

20.

A repeat loop _______.

a)

Runs a command as long as a certain condition is met

b)

Runs a command a set number of times

c)

Runs a command n times with a variable to increment each time

d)

Runs in the background continuously as long as the program is running

21.

A for loop _______.

a)

Runs a command as long as a certain condition is met

b)

Runs a command n times

c)

Runs a command n times with a variable to increment each time

d)

Runs in the background continuously as long as the program is running

22.

A while loop __________.

a)

Runs a command as long as a certain condition is met

b)

Runs a command n times

c)

Runs a command n times with a variable to increment each time

d)

Runs in the background continuously as long as the program is running

23.

Which pseudocode best represents the given code?

a)

On button B is pressed: increase the amount spent by 1 and display "-$". Set the value of total balance to the amount earned minus the amount spent. Lastly, display the value of the total balance.

b)

On button B is pressed: decrease the amount spent by 1 and display "-$". Set the value of total balance to the amount earned plus the amount spent. Lastly, display the value of the total balance.

c)

On button B is pressed: increase the amount spent by 1 and display "-$". Set the value of total balance to the amount spent plus the amount earned. Lastly, display the value of the total balance.

d)

On button B is pressed: decrease the amount spent by 1 and display "-$". Set the value of total balance to the amount spent minus the amount earned. Lastly, display the value of the total balance.

24.

According to the flowchart, what happens when the variable C is less than eleven?

a)

Print C

and increase c by 1

b)

The program stops.

c)

The program loops back to the start.

d)

The program skips the next step.

25.

Which of the following is not an example of a number variable

a)

basketball score

b)

running speed

c)

height

d)

favorite color

26.

Which of the following is not an example of a string variable?

a)

current city

b)

today's lunch menu

c)

amount of questions correct

d)

shirt color

27.

What is the primary purpose of a loop in programming?

a)

To execute a block of code once

b)

To repeat a block of code multiple times

c)

To store data

d)

To define a variable

28.

Which of the following is an example of a constant?

a)

is it raining?

b)

current temperature

c)

user age

d)

PI

29.

What is the main purpose of using pseudocode?

a)

To create a visual representation of a program

b)

To write code in a specific programming language

c)

To outline the logic of a program in plain language

d)

To compile a program

30.

Which of the following is an example of a number variable?

a)

username

b)

favorite movie

c)

age

d)

is it sunny?

31.

What is the main purpose of using variables in programming?

a)

To execute code multiple times

b)

To define a constant value

c)

To create a loop

d)

To store data that can change

32.

Which of the following best describes a Boolean variable?

a)

A variable that stores numerical values

b)

A variable that stores a sequence of characters

c)

A variable that can only hold true or false values

d)

A variable that can hold any type of data

33.

Which of the following is an example of a string variable?

a)

temperature

b)

is it raining?

c)

user age

d)

username

34.

Which of the following best describes a string variable?

a)

A variable that can only hold true or false values

b)

A variable that can hold any type of data

c)

A variable that stores a sequence of characters

d)

A variable that stores numerical values

35.

The action of doing something over and over again.

a)

Iteration

b)

Bugging

c)

Programming

d)

pseudocode

36.

What are the pink blocks an example of?

a)

Conditionals

b)

Loops

c)

Functions

d)

variables

37.

What concept repeats whatever is inside it?

a)

Conditional

b)

Variable

c)

Loop

d)

Function

38.

Which option bellow correctly plots these points (3,2), (1,4), (0,2)

a)

b)

c)

d)