Vidyalelo
Python · Q51

Python Sets MCQs: Exam

Programming · Python · question 51

Q51

Is the following Python code valid? a=3,4,7,5 print(a[2][0])

A.
Yes, 7 is printed
B.
Error, elements of a set can't be printed
C.
Error, subsets aren't allowed
Answer
D.
Yes, {7,5} is printed

Answer: Option C

Solution

Answer: Option C
No explanation is given for this question Let's Discuss on Board