wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Ozaria CH1L1-4: Exam Review

Total questions: 20

Worksheet time: 10mins

Name
Class
Date
1.

Fill in the blank: ________ is the order in which lines of code are written and executed.

a)

Sequence

b)

Loop

c)

Condition

d)

Function

2.

My friend liked the following aspect of my game:

(a)  

3.

An algorithm is:

a)

a step-by-step procedure for solving a problem

b)

a type of computer hardware

c)

a programming language

d)

a computer virus

4.

Method - ______ that an object can make in the game.

a)

actions

b)

colors

c)

levels

d)

scores

5.

A syntax bug is different than a logic bug in which of the following ways?

a)

A syntax bug is caused by incorrect code structure, while a logic bug is caused by incorrect program logic.

b)

A syntax bug is caused by incorrect program logic, while a logic bug is caused by incorrect code structure.

c)

Both syntax and logic bugs are caused by incorrect code structure.

d)

Both syntax and logic bugs are caused by incorrect program logic.

6.

Look at the code snippet shown. What type of error is this? Why do you think so?

a)

It is a syntax error because the code does not follow the correct structure.

b)

It is a logical error because the output is not as expected.

c)

It is a runtime error because the code crashes during execution.

d)

It is a semantic error because the meaning of the code is incorrect.

7.

Object - an ______ in the game that can be controlled or moved.

a)

object

b)

score

c)

level

d)

sound

8.

Input & Output Example 1. Buying something Input: ________ Output: ________

a)

Input: Money; Output: Purchased item

b)

Input: Item; Output: Money

c)

Input: Store; Output: Money

d)

Input: Purchased item; Output: Money

9.

In the code snippet:

for index in range(4): helper.moveLeft() helper.build("leftArrow")

What number of times will the loop repeat its actions?

a)

4

b)

2

c)

3

d)

5

10.

What is a Syntax Error?

a)

A mistake made in an algorithm that does not follow the grammar rules of the programming language.

b)

A logical error that causes the program to run incorrectly.

c)

A type of error that occurs when the program runs out of memory.

d)

An error that occurs due to incorrect output from the program.

11.

Fill in the blank: An ________ is a sequence of instructions that can be used to solve a problem.

a)

algorithm

b)

variable

c)

database

d)

compiler

12.

Sequences are:

a)

the order in which lines of code are written and excuted.

b)

a type of geometric shape

c)

a mathematical operation

d)

a random collection of objects

13.

What is a Logic Error?

a)

A mistake made in an algorithm that causes it to behave in a way that you don’t expect.

b)

A syntax mistake that prevents code from running.

c)

An error that occurs only when the program is compiled.

d)

A hardware malfunction in the computer.

14.

What is the first step in the example of baking cookies?

a)

Bake

b)

Gather ingredients

c)

Mix ingredients

d)

Measure ingredients

15.

What did you like about your friend’s game?

a)

I liked the creativity in my friend’s game.

b)

I did not enjoy anything about my friend’s game.

c)

I found the game too difficult to play.

d)

I thought the game was boring.

16.

Loops help you code your game more efficiently by:

a)

allowing you to repeat actions without rewriting code

b)

making the game graphics more colorful

c)

increasing the size of your code

d)

removing all bugs automatically

17.

Mark where the Hero will end up. (Fill in the blank: The Hero will end up at the position ___. The starting position is marked with a red dot.)

a)

The Hero will end up at the position two spaces up and two spaces right from the starting red dot.

b)

The Hero will end up at the position three spaces down and one space left from the starting red dot.

c)

The Hero will end up at the position one space up and three spaces right from the starting red dot.

d)

The Hero will end up at the position two spaces down and two spaces left from the starting red dot.

18.

What is a loop in programming?

a)

A) A command that lets you repeat an action multiple times in your code.

b)

B) A command that stops your code.

c)

C) A command that creates a new variable.

d)

D) A command that deletes data.

19.

Which of the following is NOT a step in the example of baking cookies?

a)

A) Gather ingredients

b)

B) Measure ingredients

c)

C) Mix ingredients

d)

D) Decorate cookies

20.

What will happen if this code is run?

a)

The code will execute without any errors.

b)

The code will throw a syntax error.

c)

The code will result in an infinite loop.

d)

The code will print nothing to the output.