A

Admin • 828.03K Points
Coach

Q. What does `__dict__` do in a Python object?

  • (A) Lists class variables
  • (B) Stores method references
  • (C) Stores attributes in dictionary form
  • (D) Displays inheritance tree
  • Correct Answer - Option(C)
  • Views: 10
  • Filed under category Python
  • Hashtags:

Explanation by: Admin
`__dict__` is a dictionary containing all the writable attributes of an object.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.