wayground logo

Free Printable Worksheets

NEW

Font size

S
M
L
XL
Worksheets

Project Stem Python Unit 1 Test Review

Total questions: 17

Worksheet time: 9mins

Name
Class
Date
1.

Which of the following is not an output device

a)

Speaker

b)

Monitor

c)

Barcode Scanner

d)

Plotter

2.

Which of the following can be considered as both an input and an output device

a)

Scanner

b)

Keyboard

c)

Headphones with mike

d)

Speaker

3.

Which of the following is an advantage of main memory over secondary memory in most computers

a)

More memory available

b)

Faster access time

c)

Data is more permanent

d)

Can be used to hold larger data files

4.

Which is not an example of secondary memory

a)

Hard disk drive

b)

Flash drive

c)

CD/DVD drive

d)

RAM

5.

Which software controls access to memory?

a)

Operating System

b)

Compiler

c)

Application

d)

None of the above

6.

Which of the following is a valid variable name?

a)

1stname

b)

first name

c)

first#name

d)

firstName

7.

Which of the following is not a data type in Python?

a)

string

b)

int

c)

float

d)

double

8.

Which data type would you use to store 5.37?

a)

int

b)

float

c)

string

d)

double

9.

What would be output by the following code:


print ("Three blind mice\nsee how they run.")

a)

Three blind mice see how they run.

b)

Three blind mice

see how they run.

c)

Three blind mice see how they run.

d)

Nothing, an error will occur

10.

What is output by the following code (assume the user enters 1 and 5)?


num1 = int(input("Enter a number: "))

num2 = int(input("Enter another number: "))

print ("The sum is "+"num1"+"num2")

a)

The sum is 1 5

b)

The sum is 6

c)

The sum is num1 num2

d)

The sum is num1num2

11.

Which print statement would correctly print the sum of two integer variables n1 and n2?

a)

print (n1 + n2)

b)

print ("n1 + n2")

c)

print ("n1" + "n2")

d)

none of the above

12.

Consider the following code:


x = input ("Enter your age: ")

print ("Your age is " + x)


What is the data type of the variable x?

a)

double

b)

float

c)

int

d)

string

13.

Which of the following print statements would correctly output:


He replied, "That is not how we do things here."

a)

print ("He replied, That is not how we do things here.")

b)

print ("He replied" + "That is not how we do things here.")

c)

print ("He replied, \"That is not how we do things here."\")

d)

print ("He replied, \"That is not how we do things here.\"")

14.

Which of the following following could be stored in a string variable?

a)

3

b)

7.8

c)

dog

d)

All of the above

15.

What is the decimal equivalent of 01101 binary?

a)

1101

b)

3

c)

13

d)

10

16.

What is the binary equivalent of 9 decimal?

a)

1101

b)

1001

c)

0101

d)

0110

17.

How many digits are there in the binary number system?

a)

1

b)

2

c)

10

d)

depends on the number