CPModule 3 Making Decisions

CPModule 3 Making Decisions

9th - 12th Grade

25 Qs

quiz-placeholder

Similar activities

AP CSP Unit 7: Parameters, Returns, and Libraries

AP CSP Unit 7: Parameters, Returns, and Libraries

9th - 12th Grade

26 Qs

CS Principles - Unit 3 Quiz

CS Principles - Unit 3 Quiz

9th - 12th Grade

20 Qs

Intro to CS Semester 1 Unit 3 quiz

Intro to CS Semester 1 Unit 3 quiz

12th Grade

20 Qs

VISUAL BASIC 6

VISUAL BASIC 6

9th - 10th Grade

25 Qs

CS Python Fundamentals Unit 3 Review

CS Python Fundamentals Unit 3 Review

9th - 12th Grade

20 Qs

Intro to CS Unit 3 Review

Intro to CS Unit 3 Review

9th - 12th Grade

25 Qs

Introduction to Programming

Introduction to Programming

9th - 12th Grade

25 Qs

Python year 9

Python year 9

8th - 11th Grade

20 Qs

CPModule 3 Making Decisions

CPModule 3 Making Decisions

Assessment

Quiz

Computers

9th - 12th Grade

Easy

Created by

Marcia Bernas

Used 15+ times

FREE Resource

25 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

When do you use an else statement?

To tell what will happen when an if-statement is false

To end an IF statement

To handle string values

To Input a variable

2.

FILL IN THE BLANK QUESTION

1 min • 1 pt

Consider the following code:


word = "kangaroo"


if (word == "KANGAROO"):

print ("TRUE")

else:

print ("FALSE")


What is output?

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Consider the following code:

if (90 < = x <= 100)


it should be rewritten as:

if (90 < = x <= 100):

if (90 < = x and <= 100):

if (90 < = x and x <= 100):

Nothing, the if statement is correct

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is NOT true about all algorithms?

All algorithms can only do number calculations

All algorithms have clear instructions

All algorithms stop in a finite amount of time

All algorithms have an order

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

The following code could be rewritten using:

if (x > 12):

if (x < 34):

not

or

and

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Write the code to test if num1 and num2 are NOT the same.

if (num1 != num2 )

if (num1 == num2 )

if (num1 = num2)

if (num1 < num2 )

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Both conditions must be true

and

!=

or

==

not

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?