Question: Object Identity in OOP: Choose the correct option and justify your answer. class Employee: def _ _ init _ _ ( self , name )

Object Identity in OOP: Choose the correct option and justify your answer.
class Employee:
def __init__(self, name):
self.__name = name
A1= Employee(Guido Van Rossum)
A2= Employee(Guido Van Rossum)
Which of the following suits the best?
A. id(A1) and id(A2) will have different values.
B. id(A1) and id(A2) will have the same values.
C. None of the above.
D. Two objects with the same values of the attribute cannot be created

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!