
Introduction To Python - For Loop
Presentation
•
Computers
•
8th Grade
•
Medium
Ayomikun J Sodipe
Used 5+ times
FREE Resource
40 Slides • 30 Questions
1
2
Read Questions & carefully
QUESTIONS AHEAD
3
Match
Match these following words to their meanings
Algorithm
Programming
Python
Sequencing
A step-by-step set of instructions
The process of writing code
A text based programming language
The order in which tasks are performed
A step-by-step set of instructions
The process of writing code
A text based programming language
The order in which tasks are performed
4
Multiple Choice
What is variable?
A variable is a named storage location that can hold data & values.
5
Multiple Choice
To repeat until a particular condition is true use:
While loop
For loop
If loop
Indentation
6
Multiple Choice
Python is an example of a:
Text-based programming language
Visual-based programming language
Block-based programming language
Language written in JavaScript
7
8
9
10
11
12
Read Questions & carefully
QUESTIONS AHEAD
13
Match
Match the following Keywords to their meanings
Iteration
Sequence
Syntax
Strings
Variable
Repeating a block of code
Ordered collection of items
Set of rules for writing code
Text (word) data type (within quotes)
Named storage location to store value
Repeating a block of code
Ordered collection of items
Set of rules for writing code
Text (word) data type (within quotes)
Named storage location to store value
14
Multiple Choice
What is a For Loop?
A for loop repeats a block of code a specified number of times.
15
Multiple Choice
True or False.
Lists, Tuples, & Strings are all examples of sequences?
16
Match
Match these Symbols to their appropriate Data type & Data Structure, in python
( )
{ }
[ ]
" "
Tuple
Dictionary
List
String
Tuple
Dictionary
List
String
17
18
19
20
21
Read Questions & carefully
QUESTIONS AHEAD
22
Multiple Choice
What will be the output of the following code?
Python
P
Y
T
H
O
N
PYTHON
p
y
t
h
o
n
23
Multiple Choice
What will be the output of the following code?
h
e
l
l
o
HELLO
hello
An error occurs.
24
25
26
27
Read Questions & carefully
QUESTIONS AHEAD
28
Multiple Choice
What will be the output of the following code?
Nigeria
Canada
Japan
Brazil
Japan
Australia
Nigeria
Japan
"Nigeria
Canada
Japan"
29
Multiple Choice
What will be the output of the following code?
Math
Science
History
Literature
Art
History
Science
Math
30
31
32
33
Read Questions & carefully
QUESTIONS AHEAD
34
Multiple Choice
What would this code output?
35
Multiple Choice
What will be the output of the following code?
2 6 8 10 12
2
4
6
8
10
12
10
8
6
4
2
2
4
6
8
10
12
36
Answer Explanation...
This for loop iterates
using the range (start, stop, step) function,
where: start = 2 → The loop starts at 2.
stop = 12 →The loop stops before reaching 12 (exclusive).step = 2 →
The loop increments i by 2 in each iteration.
37
Multiple Choice
What will be the output of the following code?
10
8
6
4
No output.
4
6
8
10
10
8
6
38
Multiple Choice
What will be the output of the following code?
39
Multiple Choice
What will be the output of the following code?
i
i
i
3
3
3
40
41
42
Multiple Choice
What will be the output of the following code?
0 1 2 3
0 1 2
1 2 3 4
43
Multiple Choice
What will be the output of the following code?
h e l
h
h e l l o
h e
44
Multiple Choice
What will be the output of the following code?
(0,0) (0,1) (1,0) (1,1) (2,0) (2,1)
(0,0) (1,0) (2,0)
(0,0) (1,0)
(0,1) (1,1) (2,1)
45
46
47
48
49
50
Read Questions & carefully
QUESTIONS AHEAD
51
Multiple Choice
What is a Dictionary dict () in Python Programming? is a data structure that stores key-value pairs, which allows data to be stored and retrieved
A collection of values stored in order, accessible by position
A collection of unique values stored without order
A fixed sequence of characters used for text processing
A data structure that stores key-value pairs, allowing data to stored and found easily
52
Multiple Choice
True or False.
Is Dictionary an examples of sequences?
53
54
55
56
57
Read Questions & carefully
QUESTIONS AHEAD
58
Multiple Choice
What will be the output of the following code?
John
25
John: name
25: age
name
age
{'name': 'John', 'age': 25}
59
Multiple Choice
What will be the output of the following code?
60
Multiple Choice
What will be the output of the following code?
61
62
63
64
Read Questions & carefully
QUESTIONS AHEAD
65
Multiple Choice
What will be the output of the following code?
Math
Science
English
Math
Science
English
90
85
88
Grade in Math : 90
Grade in Science : 85
Grade in English : 88
66
Multiple Choice
What will be the output of the following code?
Number of vowels: 4
Number of vowels: 3
Number of vowels: 5
Number of vowels: 6
67
Multiple Choice
What will be the output of the following code?
Alice
16
Grade not found
An error occurs
68
Multiple Choice
What does the term Iteration mean in Python Programming?
69
Match
Match the following Keywords in Python programming to their meanings
While Loop
Print Function
For Loop
Range
Input function
Used to execute a block of code repeatedly as long as a condition is true
Outputs data to the console or other standard output device
Used to iterate over a sequence (like a list or a string)
Generates a sequence of numbers
Allows user input from the console
Used to execute a block of code repeatedly as long as a condition is true
Outputs data to the console or other standard output device
Used to iterate over a sequence (like a list or a string)
Generates a sequence of numbers
Allows user input from the console
70
Show answer
Auto Play
Slide 1 / 70
SLIDE
Similar Resources on Wayground
62 questions
Relative Dating and Fossil Quiz Review
Presentation
•
8th Grade
65 questions
Mental Health Overview
Presentation
•
8th Grade
62 questions
8.27-8.28 Review
Presentation
•
8th Grade
63 questions
Module 3, Lesson 3: The Middle Colonies
Presentation
•
8th Grade
67 questions
The establishment of Company power
Presentation
•
8th Grade
63 questions
Grade 8 DICTION & STYLE| TYPES OF AUDIENCE
Presentation
•
8th Grade
67 questions
Power of Exponents
Presentation
•
8th Grade
63 questions
Constitution Review
Presentation
•
8th Grade
Popular Resources on Wayground
10 questions
Factors 4th grade
Quiz
•
4th Grade
10 questions
Cinco de Mayo Trivia Questions
Interactive video
•
3rd - 5th Grade
13 questions
Cinco de mayo
Interactive video
•
6th - 8th Grade
20 questions
Math Review
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
20 questions
Inferences
Quiz
•
4th Grade
19 questions
Classifying Quadrilaterals
Quiz
•
3rd Grade
Discover more resources for Computers
15 questions
Review DT Year 2 Semester 2
Quiz
•
8th Grade
7 questions
Internet Privacy and Digital Awareness
Flashcard
•
8th Grade
18 questions
Company Logos
Quiz
•
6th - 8th Grade
10 questions
Exploring Digital Citizenship Essentials
Interactive video
•
6th - 10th Grade
18 questions
Early Video Games
Quiz
•
6th - 8th Grade