A

Admin • 833K Points
Coach

Q. What will be the output of the following Python code?

Code:
l=[2, 3, [4, 5]] l2=l.copy() l2[0]=88 l l2
  • (A) [88, 2, 3, [4, 5]] [88, 2, 3, [4, 5]]
  • (B) [2, 3, [4, 5]] [88, 2, 3, [4, 5]
  • (C) [88, 2, 3, [4, 5]] [2, 3, [4, 5]]
  • (D) [2, 3, [4, 5]] [2, 3, [4, 5]]
  • Correct Answer - Option(B)
  • Views: 25
  • Filed under category Python
  • Hashtags:

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.

Be the first to start discuss.