Home / Programming MCQs / Python MCQs / Question

M

Mr. Dubey • 51.43K Points
Coach

Q. What is the output of the following program?
D = {1 : 1, 2 : '2', '1' : 1, '2' : 3}
D['1'] = 2
print(D[D[D[str(D[1])]]])

(A) 2
(B) 3
(C) „2‟
(D) KeyError

No solution found for this question.
Add Solution and get +2 points.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.