Which of these about a set is not true?
Python Set

Quiz
•
Other
•
University
•
Hard
Gokul Chinnathurai
Used 101+ times
FREE Resource
40 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Mutable data type
Allows duplicate values
Data type with unordered values
Immutable data type
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is not the correct syntax for creating a set?
set([[1,2],[3,4]])
set([1,2,2,3,4])
set((1,2,3,4))
{1,2,3,4}
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following Python code?
nums = set([1,1,2,3,3,3,4,4])
print(len(nums))
7
Error, invalid syntax for formation of set
4
8
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following Python code?
a = [5,5,6,7,7,7]
b = set(a)
def test(lst):
if lst in b:
return 1
else:
return 0
for i in filter(test, a):
print(i,end=" ")
5 5 6
5 6 7
5 5 6 7 7 7
5 6 7 7 7
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following statements is used to create an empty set?
{ }
set()
[ ]
( )
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following Python code?
>>> a={5,4}
>>> b={1,2,4,5}
>>> a<b
{1,2}
True
False
Invalid operation
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
If a={5,6,7,8}, which of the following statements is false?
print(len(a))
print(min(a))
a.remove(5)
a[2]=45
Create a free account and access millions of resources
Similar Resources on Quizizz
40 questions
Instrumentasi Kelautan 4

Quiz
•
University
41 questions
Final Day Quiz for ICT Skill Share

Quiz
•
4th Grade - Professio...
40 questions
RIA Mock ver 3

Quiz
•
University - Professi...
40 questions
Quizz_TG

Quiz
•
University
38 questions
Python Data Structures Quiz

Quiz
•
University
40 questions
Data/Digital Communications

Quiz
•
University
44 questions
Basics of Python Programming

Quiz
•
University
40 questions
Kuis Robotika

Quiz
•
University
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