

Python Programming Basics Flashcard
Flashcard
•
Computers
•
12th Grade
•
Practice Problem
•
Hard
Wayground Content
FREE Resource
Student preview

9 questions
Show all answers
1.
FLASHCARD QUESTION
Front
What will be the output?
name = "Dave"
print ("name")
Back
name
2.
FLASHCARD QUESTION
Front
A programmer wants to write a while loop that continues to run as long as the user's input is less than 100. Which of the following is the correct loop condition? Options: while user_input < 100:, while user_input > 100:, while user_input == 100:, while user_input != 100:
Back
while user_input < 100:
3.
FLASHCARD QUESTION
Front
What will be the output of the following Python code?
favorite_colors = ['red', 'blue', 'green', 'yellow']
favorite_colors.append('purple')
print(len(favorite_colors))
Back
5
4.
FLASHCARD QUESTION
Front
Given the dictionary students = {'John': 10, 'Jane': 11, 'Joe': 10}, what is the correct way to print Jane's age?
Back
print(students['Jane'])
5.
FLASHCARD QUESTION
Front
What is the output of the following code?
Python code block:
def is_even(number):
if number % 2 == 0:
return True
else:
return False
print(is_even(9))
Back
False
6.
FLASHCARD QUESTION
Front
Which line of code correctly opens a file named data.txt to add new information without erasing existing content? Options: file = open('data.txt', 'r'), file = open('data.txt', 'w'), file = open('data.txt', 'a'), file = open('data.txt', 'x')
Back
file = open('data.txt', 'a')
7.
FLASHCARD QUESTION
Front
What is the output if the user types "Python"?
Back
Try again!
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
9 questions
Pengujian Pepasangan Pendawaian
Flashcard
•
KG - University
10 questions
Microscopes are Alive?
Flashcard
•
10th Grade
15 questions
College Algebra Semester 1 Review
Flashcard
•
12th Grade
12 questions
Topic 1 C++ Programming
Flashcard
•
12th Grade
11 questions
Homeostasis and the endocrine system
Flashcard
•
KG
10 questions
Technology vocabulary
Flashcard
•
University
8 questions
Tablet Parts
Flashcard
•
KG
4 questions
FHS - PM/Standard 7 Review
Flashcard
•
10th Grade - University
Popular Resources on Wayground
8 questions
Spartan Way - Classroom Responsible
Quiz
•
9th - 12th Grade
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
14 questions
Boundaries & Healthy Relationships
Lesson
•
6th - 8th Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
3 questions
Integrity and Your Health
Lesson
•
6th - 8th Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
9 questions
FOREST Perception
Lesson
•
KG
20 questions
Main Idea and Details
Quiz
•
5th Grade