Exploring Conditionals in Computer Science

Exploring Conditionals in Computer Science

Assessment

Interactive Video

Mathematics

6th - 10th Grade

Hard

Created by

Emma Peterson

FREE Resource

7 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Why do humans adapt their behavior based on weather conditions?

To impress others

To save money

To follow fashion trends

To stay comfortable and safe

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the purpose of conditional statements in programming?

To make programs run faster

To make the code look cleaner

To allow programs to respond to different conditions

To reduce the size of the code

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does an 'if statement' use to determine whether to execute a block of code?

A loop counter

A numerical value

A boolean expression

A string comparison

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

In the context of an 'if statement', what does a boolean expression evaluate to?

True or False

A string

A number

A character

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the first step in the practical example of using conditionals?

Moving the sprite

Drawing the background

Creating a sprite

Adding a conditional statement

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What question does the boolean expression ask in the practical example?

Is the sprite's y position greater than 200?

Is the sprite's x position less than 200?

Is the sprite's x position greater than 200?

Is the sprite's y position less than 200?

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What happens to the sprite if it moves past the middle of the screen in the example?

It stops moving

It moves faster

It changes its look

It disappears