The following class is defined: class Person:     pass An instance of this class was created: p = Person() How to get the class name as a string from this instance? (select two)

Questions & AnswersCategory: PythonThe following class is defined: class Person:     pass An instance of this class was created: p = Person() How to get the class name as a string from this instance? (select two)
Lokesh Kumar Staff asked 2 years ago

The following class is defined:

class Person:
    pass

An instance of this class was created:

p = Person()

How to get the class name as a string from this instance? (select two)
a. p.__class__
b. p.__name__
c. p.__class__.__name__
d. type(p).__name__