
Python Sets
Authored by surag patel
Computers
9th - 12th Grade
Used 1+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
32 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which one of these is a set?
myset = ('apple', 'banana', 'cherry')
myset = ['apple', 'banana', 'cherry']
myset = {'apple', 'banana', 'cherry'}
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Set items cannot be removed after the set has been created.
True
False
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
A set cannot have two items with the same value.
True
False
4.
FILL IN THE BLANK QUESTION
1 min • 1 pt
Select the correct function for returning the number of items in a set:
fruits = {'apple', 'banana', 'cherry'}
print(___________(fruits))
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
True or False. You can access set items by referring to the index.
True
False
6.
FILL IN THE BLANK QUESTION
1 min • 1 pt
Check if "apple" is present in the fruits set.
fruits = {"apple", "banana", "cherry"}
if "apple" _______ fruits: print("Yes, apple is a fruit!")
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Consider the following code:
thisset = {'apple', 'banana', 'cherry'}
print('banana' not in thisset)
What will be the printed result?
True
False
{'apple', 'cherry'}
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?
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade
20 questions
Figurative Language Review
Quiz
•
6th Grade