wayground logo

Free Printable Worksheets

NEW

Font size

S
M
L
XL
Worksheets

Python Basics or Syntax

Total questions: 17

Worksheet time: 9mins

Name
Class
Date
1.

The number or word we give to a variable Example name="Robert"

What does the word Robert Refers to?

a)

Value

b)

Text

c)

name

d)

Information

2.

The word (command) used to display numbers and text on the screen

a)

print

b)

PRINT

c)

OUTPUT

d)

COMMAND

3.

What is a variable in Programming?

a)

A box(memory location) where you store values

b)

a type of graphics

c)

Data type

d)

a type of memory

4.

What symbol is used in python to assign values to a variable?

a)

equals =

b)

asterisk *

c)

forward slash /

d)

plus + 

5.

What will be the output?

name = 'Grace Kitosi'

print (name)

a)

grace kitosi

b)

Grace Kitosi

c)

Grace kitosi

d)

name

6.

What is a input?

a)

A function that allows us to ask the user to enter some data.

b)

Data displayed on a screen.

c)

A function

d)

To plug in something.

7.

What is an output?

a)

An output

b)

DA piece of data that is shown on the screen.

c)

Data that the user enters

8.

Which of the following is correct?

a)

name=input

b)

input=name

c)

name=input()

d)

input()=name

9.

If Python were to get into a fight with JavaScript, who would win?

a)

Python

b)

JavaScript

10.

When you have an error in your code what is the term to summarize finding and fixing that error?

a)

Error checking

b)

Syntax finder

c)

Debugging

d)

Error finder

11.

A data type than can have one of two values: True or False

a)

Boolean

b)

modulo

c)

variable

d)

interpreter

12.

Which command allows a user to type when the program is running?

a)

PRINT

b)

INPUT

c)

input

d)

print

13.

First Name = "Bara"

Is the above code correct?

a)

YES

b)

NO

14.

FirstName = "Hawa"

Is the above code correct?

a)

YES

b)

NO

15.

1Name = "Bara Alawi"

Is the above code correct?

a)

YES

b)

NO

16.

What is the name of this software?

a)

Personal Computer

b)

PyCharm

17.

What is the name of this software?

a)

Personal Computer

b)

PyCharm