Search Header Logo
Introduction to Programming

Introduction to Programming

Assessment

Presentation

Computers

9th - 10th Grade

Medium

Created by

Calum Gordon

Used 15+ times

FREE Resource

7 Slides • 20 Questions

1

Introduction to Programming

by BSN Computing

2

media

3

media

4

Multiple Select

Question image

In this lesson I am going to learn to use ... ?

1

Sequence in programs

2

Selection in programs

3

Repetition (while) in programs

4

Iteration (one-dimensional) in programs

5

media

6

Multiple Select

Which two of these programs would generate a run-time error caused by sequencing?

1

a = 3

b = 4

c = a + b

b = c * 2

print(a+b)

2

a = 3

b = 4

b = c * 2

c = a + b

print(a+b)

3

a = 3

b = a + b

c = a + b

b = c * 2

print(a+b)

4

a = a + a

b = a * 2

c = a + b

b = c * 2

print(a+b)

7

Open Ended

Write a short Python program that swaps the values of three variable, to illustrate the importance of sequence in code. So:

var2 = var1

var3 = var2

var1 = var3

8

media

9

Fill in the Blank

Question image

Type the line number where a selection structure starts ...

10

Fill in the Blank

Question image

Type the line number where a selection structure ends ...

11

Multiple Choice

Question image

What is output if:

vegName = "broccoli"

vegNum = 1

vegNumRandom = 2

1

Invalid vegetable number

2

So you think you can eat 1 broccoli do you?

Ah ha, the computer can eat 2 broccoli.

3

Looks like we both love broccoli

4

So you think you can eat 1 broccoli do you?

You win. The computer can only eat 2 broccoli.

12

Multiple Choice

Question image

What is output if:

vegName = "carrots"

vegNum = 21

vegNumRandom = 20

1

Invalid vegetable number

2

So you think you can eat 21 carrots do you?

Ah ha, the computer can eat 20 carrots.

3

Looks like we both love carrots.

4

So you think you can eat 21 carrots do you?

You win. The computer can only eat 20 carrots.

13

Multiple Choice

Question image

What is output if:

vegName = ""

vegNum = 0

vegNumRandom = 1

1

Invalid vegetable number

2

So you think you can eat 0 do you?

Ah ha, the computer can eat 1.

3

You must enter a vegetable name.

4

So you think you can eat 0 do you?

You win. The computer can only eat 1.

14

Open Ended

Write a selection block in Python that displays a student's Key Stage (1 to 5) depending on the year at school that is input

15

media

16

Multiple Select

Choose two other terms for repetition of a block of code ...

1

Looping

2

Iteration

3

Recursion

4

Reflection

17

Multiple Choice

Which one is a conditional loop in Python?

1

while ...

2

for ... in range(...)

3

for ... in ...

4

repeat ... until ...

18

Multiple Choice

Which one is a count-controlled loop in Python?

1

while ...

2

for ... in range(...)

3

for ... in ...

4

repeat ... until ...

19

Multiple Choice

Which one is an iterative loop over a data structure in Python?

1

while ...

2

for ... in range(...)

3

for ... in ...

4

repeat ... until ...

20

Multiple Choice

Which one is a loop that is not available in Python?

1

while ...

2

for ... in range(...)

3

for ... in ...

4

repeat ... until ...

21

Open Ended

Write a conditional loop in Python that asks the user to enter a number divisible by 2 and keeps asking for a number until a suitable number is input. It then outputs the number.

22

Open Ended

Write a count-controlled loop in Python that outputs the times table of a number input by the user, from 1 x up to 12 x the number.

23

Open Ended

Write an iterative loop in Python that counts the number of vowel letters in a string input by the user and outputs that number.

24

media

25

Multiple Select

Question image

In this lesson I have learned to use ...

1

Sequence in programs

2

Selection in programs

3

Repetition (while) in programs

4

Iteration (one-dimensional) in programs

26

Open Ended

Question image

Thinking Hard

What was the most important thing you've learned in this lesson? Why?

(press Shift+Enter to take a new line ...)

27

Poll

Question image

How much of this lesson have you understood?

None of it

Some of it

Most of it

All of it

Introduction to Programming

by BSN Computing

Show answer

Auto Play

Slide 1 / 27

SLIDE