In Python, a dictionary consists of:
iav ML Study Group Pop Quiz 4

Quiz
•
Computers
•
1st - 2nd Grade
•
Hard

Bob Balooey
Used 1+ times
FREE Resource
10 questions
Show all answers
1.
MULTIPLE SELECT QUESTION
45 sec • 1 pt
Key:Value pairs
Value:Key pairs
Translation maps
Languange<->Language encodings
2.
FILL IN THE BLANK QUESTION
1 min • 1 pt
Given a dictionary: testdict
Write the command to see all keys from the dictionary
3.
MULTIPLE SELECT QUESTION
45 sec • 1 pt
Select the methods which will REMOVE the number 4 from the list:
numlist=[1,2,3,4]
numlist.drop(4)
numlist.drop(3)
numlist.pop(3)
numlist.pop()
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which is the expected output from:
test_tuple("red","green","blue")
test_tuple[1]= "pink"
print(test_tuple)
("red","pink","blue")
("pink","green","blue")
test_tuple
TypeError: 'tuple' object does not support item assignment
5.
MULTIPLE SELECT QUESTION
45 sec • 1 pt
Defining your own custom data classes instead of using the defaults has the advantages of:
shortening the syntax for variable instantiation
pretty-printing the string representation with .__repr__()
self-documentation with type annotation
faster loading times
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
The difference between tuples and namedtuples is that
namedtuples are mutable
tuples cannot be named
namedtuple elements can be accessed through an identifier instead of just the index position
tuples don't exist as a native class in Python
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
We instantiate a set with:
Brackets, ()
Square Brackets, []
Curly Brackets, {}
Double Quotes: " "
Create a free account and access millions of resources
Similar Resources on Quizizz
15 questions
Object Oriented Programming

Quiz
•
1st Grade
15 questions
Comunicarea pe internet

Quiz
•
1st - 10th Grade
15 questions
Conocimientos Básicos de Python

Quiz
•
1st Grade
15 questions
Python MDS 2

Quiz
•
1st Grade
7 questions
6б сынып

Quiz
•
1st Grade
10 questions
BÀI KIỂM TRA GIỮA KÌ 2 - LỚP 3

Quiz
•
1st - 10th Grade
10 questions
Bàn phím máy tính

Quiz
•
KG - 1st Grade
15 questions
Conditionals

Quiz
•
1st - 12th 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
10 questions
American Flag

Quiz
•
1st - 2nd Grade
10 questions
Identifying equations

Quiz
•
KG - University
10 questions
2nd Grade math review

Quiz
•
2nd Grade
26 questions
Place Value Review

Quiz
•
2nd Grade
25 questions
2.4A Add Subtract within 20 quickly: set 3

Quiz
•
1st - 3rd Grade
12 questions
Summer Trivia

Quiz
•
1st - 5th Grade
15 questions
Music 2016

Quiz
•
KG - 12th Grade
44 questions
logos

Quiz
•
KG - University