
Python PCEP Flashcard #2

Flashcard
•
Science
•
6th - 8th Grade
•
Hard
Wayground Content
FREE Resource
Student preview

15 questions
Show all answers
1.
FLASHCARD QUESTION
Front
What is a List in Python?
Back
A List is a data type in Python that is used to store multiple items in a single variable. Lists are ordered, changeable, and allow duplicate values. Example: x = [1, 2, 3]
2.
FLASHCARD QUESTION
Front
What is the output of the following code: numbers = [5, 14, 9, 17]; for number in numbers: if number % 3 == 0: print(number)?
Back
The output will be 9, as it is the only number in the list that is divisible by 3.
3.
FLASHCARD QUESTION
Front
What does the expression 'number > 7' evaluate to if number is 10?
Back
The expression evaluates to True, as 10 is greater than 7.
4.
FLASHCARD QUESTION
Front
What symbol is used in Python to assign values to a variable?
Back
The equals sign '=' is used to assign values to a variable in Python.
5.
FLASHCARD QUESTION
Front
What is a Dictionary in Python?
Back
A Dictionary is a data type in Python that stores data in key-value pairs. Example: x = {'a': 1, 'b': 2}.
6.
FLASHCARD QUESTION
Front
What is a Tuple in Python?
Back
A Tuple is a data type in Python that is similar to a list but is immutable (cannot be changed). Example: x = (1, 2, 3).
7.
FLASHCARD QUESTION
Front
What is the difference between a List and a Tuple?
Back
The main difference is that Lists are mutable (can be changed) while Tuples are immutable (cannot be changed).
Create a free account and access millions of resources
Similar Resources on Wayground
8 questions
CS3 Lesson 3.5: Flashcard

Flashcard
•
6th - 8th Grade
11 questions
Python [Basic]

Flashcard
•
KG
10 questions
Coding 300: JavaScript/Python Vocab

Flashcard
•
7th - 8th Grade
10 questions
Computer Science

Flashcard
•
7th Grade
10 questions
Python Variables

Flashcard
•
6th Grade
16 questions
Python L1 Knowledge Check

Flashcard
•
6th - 8th Grade
15 questions
DJI Tello Drones

Flashcard
•
5th - 7th Grade
10 questions
Functions Review (codeHS Tracy Python)

Flashcard
•
6th - 8th Grade
Popular Resources on Wayground
10 questions
Video Games

Quiz
•
6th - 12th Grade
20 questions
Brand Labels

Quiz
•
5th - 12th Grade
15 questions
Core 4 of Customer Service - Student Edition

Quiz
•
6th - 8th Grade
15 questions
What is Bullying?- Bullying Lesson Series 6-12

Lesson
•
11th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
Discover more resources for Science
20 questions
Physical and Chemical Changes

Quiz
•
8th Grade
22 questions
Newton's Laws of Motion

Lesson
•
8th Grade
20 questions
Distance Time Graphs

Quiz
•
6th - 8th Grade
10 questions
Exploring Newton's Laws of Motion

Interactive video
•
6th - 10th Grade
17 questions
Thermal Energy Transfer

Lesson
•
6th - 8th Grade
20 questions
Physical and Chemical Changes

Quiz
•
6th Grade
10 questions
Exploring Chemical and Physical Changes

Interactive video
•
6th - 10th Grade
22 questions
Metals, nonmetals, metalloids

Quiz
•
6th Grade