wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

AI and Python: Ch.1 Revision

Total questions: 10

Worksheet time: 6mins

Name
Class
Date
1.

Which of the following example is NOT AI?

a)

Google Translate

b)

Robot waiters

c)

Apple Siri

d)

Smart Mirrors

e)

RFID tag

2.

Which of the following codes can be executed?

a)

Print(“I hate exams”)

b)

print(‘I hate exams’)

c)

Print I hate exams

d)

print(‘I hate exams”)

3.

Which of the following is a library?

a)

tts

b)

say

c)

sleep

d)

print

4.

What does time.sleep(5) mean?

a)

Make the program run faster by five times

b)

Make the program pause for 5 minutes

c)

Make the program pause for five seconds

d)

Shut down the computer after 5 seconds

5.

For the statement time.sleep(5)

Which keyword is a function?

a)

time

b)

sleep

c)

(5)

6.

What is the voice output of the program below?

import tts

Tts.say(“Merry Christmas!)

a)

The program cannot be executed.

b)

Merry Christmas!

7.

Why can’t the program be executed?

import tts

Tts.say(“Merry Christmas!”)

a)

Python is case-sensitive.

b)

No library was imported.

c)

The speaker was out of order.

d)

The program can be executed.

8.

What is the advantage of textual programming over visual programming?

a)

It is easier to understand.

b)

It looks cool.

c)

It is more advanced.

d)

It is suitable for beginners without prior knowledge in programming.

9.

Which of the following jobs is the LEAST likely to be replaced by AI?

a)

Translators

b)

Cashier

c)

Clerks

d)

Programmers

10.

import time

tts.say("I love you.")

time.sleep(3)

tts.say("But I don't love you.")

In the above example, which library is missing? (Your answer is case sensitive)

(a)