Wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Programming Concepts Quiz

Total questions: 60

Worksheet time: 30mins

Name
Class
Date
1.

What is a variable in programming?

a)

A fixed number

b)

A storage container for values

c)

A computer part

d)

A symbol

2.

Which of these is an integer?

a)

3.5

b)

"3"

c)

3

d)

True

3.

What type is "Hello"?

a)

int

b)

float

c)

str

d)

bool

4.

What type is 3.14?

a)

int

b)

float

c)

str

d)

bool

5.

What type is True?

a)

str

b)

float

c)

bool

d)

int

6.

Which of these is a string?

a)

12

b)

"12"

c)

12.0

d)

False

7.

What does int("5") return?

a)

"5"

b)

5

c)

5.0

d)

Error

8.

What does float(7) return?

a)

7.0

b)

"7"

c)

70

d)

Error

9.

What type is returned by type("hi")?

a)

int

b)

str

c)

float

d)

bool

10.

What does str(8) return?

a)

8

b)

"8"

c)

8.0

d)

Error

11.

What is a Boolean?

a)

A number

b)

A true/false value

c)

A decimal value

d)

A word

12.

What is a sprite in Scratch?

a)

A code block

b)

A character or object

c)

A variable

d)

A song

13.

Which block starts a Scratch project?

a)

When green flag clicked

b)

Forever

c)

Go to

d)

Say message

14.

Which Scratch block moves a sprite?

a)

Move 10 steps

b)

Say Hello

c)

Change costume

d)

Play sound

15.

Which is a valid Python variable name?

a)

2name

b)

name_2

c)

@value

d)

class

16.

What happens when you run x = 5; x = x + 3?

a)

x becomes 53

b)

x becomes 8

c)

x becomes 35

d)

Error

17.

Which type is 0.0?

a)

int

b)

float

c)

bool

d)

str

18.

What is 10 // 3?

a)

3

b)

3.33

c)

4

d)

Error

19.

What type is False?

a)

int

b)

float

c)

str

d)

bool

20.

Which Scratch category contains motion blocks?

a)

Looks

b)

Motion

c)

Events

d)

Operators

21.

What does bool(0) return?

a)

True

b)

False

c)

Error

d)

0

22.

What does float("5") return?

a)

"5"

b)

5

c)

5.0

d)

Error

23.

What type is returned by type(5.5)?

a)

int

b)

float

c)

str

d)

bool

24.

What is the value of 12 % 5?

a)

1

b)

2

c)

0

d)

5

25.

A variable in Scratch can store:

a)

Only numbers

b)

Only text

c)

Both numbers and text

d)

Only sprites

26.

Which block in Scratch repeats forever?

a)

Repeat

b)

Forever

c)

If

d)

Wait

27.

Which of these is NOT a Python type?

a)

int

b)

float

c)

sprite

d)

bool

28.

What does x = "10" store?

a)

int

b)

float

c)

str

d)

bool

29.

What is 4 + 4 * 2?

a)

16

b)

12

c)

8

d)

6

30.

Which Scratch block makes a sprite talk?

a)

Move 10 steps

b)

Say Hello

c)

Turn 15 degrees

d)

Repeat

31.

What is the type of 100?

a)

int

b)

float

c)

str

d)

bool

32.

What is the output of type(False)?

a)

str

b)

int

c)

bool

d)

float

33.

What is the type of "123"?

a)

int

b)

float

c)

str

d)

bool

34.

What is 5 * 2?

a)

52

b)

25

c)

10

d)

5

35.

What block changes sprite appearance?

a)

Change costume

b)

Forever

c)

Move steps

d)

Repeat

36.

What does x = 5 do?

a)

Creates a sprite

b)

Stores a value in a variable

c)

Deletes data

d)

Moves a sprite

37.

What is the result of 9 / 3?

a)

3.0

b)

3

c)

6

d)

Error

38.

Which is a float?

a)

10

b)

10.0

c)

True

d)

"10"

39.

In Scratch, which block checks conditions?

a)

If

b)

Move

c)

Say

d)

Play sound

40.

What is the output of int(4.8)?

a)

5

b)

4.8

c)

4

d)

Error

41.

Which of these is a Boolean?

a)

"True"

b)

1

c)

False

d)

"False"

42.

What is a script in Scratch?

a)

A drawing

b)

A group of blocks

c)

A sprite name

d)

A folder

43.

What type is returned by type("Python")?

a)

int

b)

str

c)

bool

d)

float

44.

Which operator multiplies numbers?

a)

+

b)

-

c)

*

d)

%

45.

Which operator finds the remainder?

a)

//

b)

%

c)

**

d)

/

46.

What is the type of 7.0?

a)

int

b)

float

c)

bool

d)

str

47.

What happens with x = 2; x = x * 4?

a)

x becomes 6

b)

x becomes 24

c)

x becomes 8

d)

Error

48.

In Scratch, what does "go to x:0 y:0" do?

a)

Moves sprite home

b)

Deletes sprite

c)

Plays music

d)

Rotates sprite

49.

Which is a valid Python variable?

a)

my-name

b)

myName

c)

1value

d)

class

50.

What is the result of float(3)?

a)

3.0

b)

"3"

c)

3

d)

Error

51.

Which type represents whole numbers?

a)

int

b)

float

c)

bool

d)

str

52.

What color is the Motion category in Scratch?

a)

Blue

b)

Yellow

c)

Purple

d)

Green

53.

What is the value of 20 % 6?

a)

2

b)

0

c)

6

d)

4

54.

What does type(True) return?

a)

int

b)

bool

c)

float

d)

str

55.

What is the result of 3 + 7 / 2?

a)

5

b)

6.5

c)

3.5

d)

10

56.

In Scratch, which block changes x position?

a)

Change x by

b)

Say

c)

Repeat

d)

Play sound

57.

What is the type of "456"?

a)

int

b)

float

c)

str

d)

bool

58.

What does bool(1) return?

a)

False

b)

True

c)

1

d)

Error

59.

What is an expression?

a)

A value

b)

A combination of values and operators

c)

A Python file

d)

A sprite name

60.

What is the output of 7 - 2 * 3?

a)

15

b)

1

c)

-1

d)

6