wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

ICT benchmarking test 1.2

Total questions: 56

Worksheet time: 42mins

Name
Class
Date
1.
What will be the output?
name = 'Dave'
print (name)
a)
Dave
b)
'Dave'
c)
name
d)
(name)
2.
What will be the output?
name = 'Dave'
greeting = "Good morning" + name
print (greeting)
a)
Good moning 'Dave'
b)
Good morning Dave
c)
Good morning name
d)
Good morning + Dave
3.

How do you insert COMMENTS in Python code?

a)

/*This is a comment*/

b)

//This is a comment

c)

#This is a comment

4.

In Python, 'Hello', is the same as "Hello"

a)

True

b)

False

5.

What does the Input function Do?

a)

outputs any sentence or word

b)

Ask the user to insert asked Data

c)

Defines what an integer or string or boolean or float

6.

What is the output of Name = print('Dave")

a)

dave

b)

"Dave"

c)

Syntax Error

d)

Dave

7.

What do we use to assign a value to a variable?

a)

+

b)

/

c)

==

d)

=

8.
What is a variable?
a)
A box(memory location) where you store values
b)
a type of graphics
c)
Data type
d)
a type of memory
9.
In python the ' INTEGER data type' can be defined as...?
a)
holds alphanumeric data as text
b)
holds whole numbers
c)
holds numbers with a decimal point
d)
holds either ‘true’ or ‘false’
10.
In python the ' FLOAT data type' can be defined as...?
a)
holds alphanumerical data
b)

holds whole numbers

c)

holds a decimal point in a number

d)
hold either true or false
11.
In python the ' BOOLEAN data type' can be defined as...?
a)
holds alphanumerical data
b)
holds whole numbers
c)
holds a number with a decimal point
d)
holds either true or false
12.
What data type would be used for storing someone's telephone numbers?
a)
Float (using a decimal point)
b)
Integer (just whole numbers)
c)
String (alphanumerical data)
13.

What is the output?

a)

True

b)

False

c)

condition1

d)

condition2

14.

This operator checks to see if one value is the same as the other value

a)

==

b)

!=

c)

>

d)

<

15.

What would be outputted here?

a)

it divides by 7!

b)

it divides by 3!

c)

It divides by 7.

d)

It divides by 3.

16.

What will be outputted?

a)

number is bigger than 10

b)

nothing

c)

an error

d)

NUMBER IS BIGGER THAN 10

17.

If else statement

a)

Outputs a message on the screen

b)

Gets data from the user

c)

A decision

d)

A loop controlled by a decision

18.
This operator means that one value is the same as the other value
a)
==
b)
!=
c)
>
d)
<
19.
This operator means that one value is not equal to another value
a)
==
b)
<=
c)
>=
d)
!=
20.

What is the output?

a)

more than 7

b)

more than 23

c)

spam

d)

7

21.

Which is NOT a data type in Python?

a)

integer

b)

boolean

c)

anchor

d)

float

22.

Which is correct?

a)

A

b)

B

23.

What is the name of the variable in this program?

a)

print

b)

colour

c)

input

d)

" "

24.

output of the following question is:

#program for text addition

# input() method

f_name= "hello"

l_name ="world"

print( f_name + l_name)

a)

helloworld

b)

hello world

c)

error

d)

f_name+l_name

25.

In programming, what is iteration (loops)?

a)

The repetition of steps within a program

b)

The order in which instructions are carried out

c)

A decision point in a program

d)

Testing a program to make sure it works

26.

What does the following code do? myAge = int (myAge)

a)

Converts the var (variable) myAge to a string

b)

Converts the var (variable) myAge to a integer

c)

Converts the var (variable) myAge from a integer to a string

d)

Converts the var (variable) myAge to if statement

27.
The second part of if, that is executed when the condition is false
a)
if
b)
else
c)
for
d)
input
28.
The character that must be at the end of the line for if, while, for etc.
a)
:
b)
;
c)
.
d)
,
29.
Data type for a whole number
a)
String
b)
Integer
c)
Boolean
d)
Float
30.

Which two statements are used to implement iteration(loops)?

a)
IF and WHILE
b)
ELSE and WHILE
c)
FOR and WHILE
d)
IF and ELSE
31.

FOR loops are

a)

loops which run an unknown number of times

b)

loops which run for a specific number of times

c)

the same as if statements

d)

not part of programming

32.

Which type of loop iterates until instructed otherwise?

a)

FOR loop

b)

WHILE loop

33.

Which kind of loop would be used?


I need a program that will keep letting me add money to a piggy bank until I get to £100.

a)

FOR Loop

b)

WHILE Loop

34.

Which kind of loop would be used?


I need a program that will keep letting me add a monthly payment for 12 months.

a)

FOR Loop

b)

WHILE Loop

35.

Which kind of loop would be used?


I need a guessing game program that will let me keep guessing until I get the right answer.

a)

FOR Loop

b)

WHILE Loop

36.

Which kind of loop would be used?


I need a revision program that will run through revision questions 4 times.

a)

FOR Loop

b)

WHILE Loop

37.
How many times does the following program print the word ‘computer’:

word= "computer"  
for num in range(1,6):
 
    print(word)
a)
5
b)
6
c)
1
d)
0
38.
What will be printed after running this FOR loop:

for number in range(6):
 
    print(number)
a)
The number 6 
b)
The numbers 0 - 5
c)
The number 5
d)
The numbers 1 - 6
39.
In the following code what will happen if the wrong password is entered:
while password != "computer":
   
    print("Enter Password: ")
 
    p
assword = input()
a)
It will log in
b)
It will keep asking to type in password
40.
What is the position of the name 'Paula' in the following list:
names = ["Paul","Phillip","Paula","Phillipa"]
a)
0
b)
1
c)
2
d)
3
41.

In Python, what are if-statements used for?

a)

Looping

b)

Indexing

c)

Decision Making

d)

Testing

42.

What is the output of the following code?


Time = "Day"

Sleepy = False

Pajamas = "Off"

if Time == "Night" and Sleepy == True:

Pajamas = "On"

print(Pajamas)

a)

off

b)

on

c)

False

d)

Day

43.

Which of the following statements are correct?

(Select 2 Answers)

a)

If is a conditional statement

b)

If is used for looping

c)

If is used for comparing and decision making

d)

If is used for error handling

44.

What will the be the output of the following code?


if (10<0) and (0 <-10):

print(“A”)

else:

print(“B”)

a)

A

b)

B

c)

AB

d)

BA

45.
A variable that can only have two values, True or False.
a)
Boolean
b)
If
c)
elif
d)
else
46.

_____ data type contain integer values with no decimal such as 1, 200, 999 etc.

a)

int

b)

float

c)

char

d)

String

47.

_____ data type contain integer values with decimal such as 10.1, 5555.0, 33.33 etc.

a)

int

b)

float

c)

char

d)

String

48.

_____ data type contain a set of characters (text) or word such as Hello, Ali, Car Type etc.

a)

int

b)

float

c)

char

d)

String

49.

Which if the values below is an integer data type?

a)

1

b)

1.0

c)

1/2

d)

"1"

50.

Which if the values below is a float data type?

a)

2

b)

2.11

c)

2/4

d)

"2.11"

51.

what is should be added to blanks in order to make the program function proberly

(a)  

52.

what should be in the first blank

(a)  

53.

what should be added to the blank

(a)  

54.

whats should be in the first blank

a)

operation == "+"

b)

operation == "-"

c)

operation == +

d)

operation == -

55.
a)

correct password == user password

b)

correct_password == user_password

c)

"correct password" == "user password"

d)

'correct_password' == 'user_password'

56.

what should be added to the third blank

a)

Average

b)

average

c)

"Average"

d)

"average"