You are on page 1of 2

Name : Date of issue : 28/06/2022

Class : 8 Date of submission : 29/06/2022


Subject : ICT Worksheet No : 02
Topic : Python programming Assessed By : Teacher

I. Choose the correct answer:


1. What is a variable? (A )
a. A box(memory location) b. a type of graphics
where you store values
c. Data type d. a type of memory

2. What symbol is used in python to assign values to a variable? ( A)

a. equals to = b. plus +

c. forward slash / d. asterisk *

3. A syntax error means your code has a 'grammar' mistake or you used
symbols/operations incorrectly ( A)

a. True b. False

4. What will be the output? ( A)

name = 'Dave'

print (name)

a. Dave b. ‘Dave’ c. name d. (name)

5. What will be the output? (B )

name = 'Dave'

greeting = "Good morning" + name

print (greeting)

a. Good moning 'Dave' b. Good morning Dave

c. Good morning name d. Good morning + Dave


6. Python is an example of a.... ( A)

a. Text-based programming language b. Object orientated programming language

c. language written in java script d. Visual-based programming language

7. What would print (10 + 16) produce? ( D)

a. 20 b. 22 c. 24 d. 26

8. Which of these would work as a piece of code? ( C)

a. IF answer == "Yes": b. if answer == "Yes"

c. if answer == "Yes": d. if answer = "yes":

9. If you want more than one option for your code, what do you use (after if) ( A)

a. elif b. else c. ifif d. none of these

10. What is the name of the environment in Python that write your programs and then test
them out? ( A)

a. Shell b. Window c. IDLE d. CLI

You might also like