What is the starting value of the variable i in the for loop if we use the range function with two parameters? for i in range(3, 10):

Python Flashcard - ForLoops CS1

Flashcard
•
Computers
•
9th Grade
•
Hard
Heather Luman
FREE Resource
Student preview

8 questions
Show all answers
1.
FLASHCARD QUESTION
Front
Back
3
2.
FLASHCARD QUESTION
Front
What does the second parameter in the range function indicate? Example: for i in range(3, 10): print(i)
Back
Ending value for 'I'
3.
FLASHCARD QUESTION
Front
In this example where the loop goes from 1 to 9 in two step increments, what is the last number to be printed? for i in range(1, 9, 2): print(i)
Back
7
4.
FLASHCARD QUESTION
Front
In this example, what is the last number to print? for i in range(10, 0, -1): print(i)
Back
1
5.
FLASHCARD QUESTION
Front
In a for loop where the loop counts up to 100 by twos, what is last value to print? for i in range(0, 100, 2): print(i)
Back
98
6.
FLASHCARD QUESTION
Front
Which for loop prints the numbers 3, 5, 7, 9? Options: for i in range(3, 10, 2): print(i), for i in range(3, 9, 2): print(i), for i in range(9): print(i), for i in range(3,9): print(i)
Back
for i in range(3, 10, 2): print(i)
7.
FLASHCARD QUESTION
Front
Three of the for loops below will provide identical values for i. Which for loop will provide values that do not match the others? for i in range(0, 5):, for i in range(5):, for i in range(0, 5, 1):, for i in range(5, 0, 1):
Back
for i in range(5, 0, 1):
8.
FLASHCARD QUESTION
Front
What would be the output of the following code: for i in range(3): print(5)
Back
5 5 5
Similar Resources on Quizizz
8 questions
Grok Module 6 Practice

Flashcard
•
7th - 8th Grade
10 questions
Python Loops Flashcard

Flashcard
•
10th Grade
10 questions
Ôn tập chủ đề F

Flashcard
•
KG
10 questions
S3 Exam Revision Page3

Flashcard
•
9th Grade
10 questions
Questions about Loops

Flashcard
•
10th Grade
9 questions
Python Programming Basics - MP2 Study

Flashcard
•
10th Grade
6 questions
R093

Flashcard
•
10th Grade
8 questions
End of Unit 3 Review

Flashcard
•
8th Grade
Popular Resources on Quizizz
15 questions
Character Analysis

Quiz
•
4th Grade
17 questions
Chapter 12 - Doing the Right Thing

Quiz
•
9th - 12th Grade
10 questions
American Flag

Quiz
•
1st - 2nd Grade
20 questions
Reading Comprehension

Quiz
•
5th Grade
30 questions
Linear Inequalities

Quiz
•
9th - 12th Grade
20 questions
Types of Credit

Quiz
•
9th - 12th Grade
18 questions
Full S.T.E.A.M. Ahead Summer Academy Pre-Test 24-25

Quiz
•
5th Grade
14 questions
Misplaced and Dangling Modifiers

Quiz
•
6th - 8th Grade
Discover more resources for Computers
17 questions
Chapter 12 - Doing the Right Thing

Quiz
•
9th - 12th Grade
30 questions
Linear Inequalities

Quiz
•
9th - 12th Grade
20 questions
Types of Credit

Quiz
•
9th - 12th Grade
20 questions
Taxes

Quiz
•
9th - 12th Grade
17 questions
Parts of Speech

Quiz
•
7th - 12th Grade
20 questions
Chapter 3 - Making a Good Impression

Quiz
•
9th - 12th Grade
20 questions
Inequalities Graphing

Quiz
•
9th - 12th Grade
10 questions
Identifying equations

Quiz
•
KG - University