ExamVeda
Login
Home
81
What will be the output of the following Python code?
>>> a={4,5,6}
>>> b={2,8,6}
>>> a-b
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
82
Which of the following statements is used to create an empty set?
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
83
If a={5,6,7}, what happens when a.add(5) is executed?
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
84
What will be the output of the following Python code snippet?
for x in set('pqr'):
	print(x*2)
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
85
What will be the output of the following Python code?
s={2, 5, 6, 6, 7}
s
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
86
What will be the output of the following Python code?
nums = set([1,1,2,3,3,3,4,4])
print(len(nums))
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board
87
Is the following Python code valid?
a={1,2,3}
b={1,2,3,4}
c=a.issuperset(b)
print(c)
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
88
Which method is used to find the symmetric difference between two sets?
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
89
What will be the output of the following Python code?
>>> a={3,4,5}
>>> b={5,6,7}
>>> a|b
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
90
Set makes use of . . . . . . . .
Dictionary makes use of . . . . . . . .
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board