python object getattr
class GfG :
email = "[email protected]"
age = 24
# initializing object
obj = GfG()
# use of getattr
print("The name is " + getattr(obj,'email'))
class GfG :
email = "[email protected]"
age = 24
# initializing object
obj = GfG()
# use of getattr
print("The name is " + getattr(obj,'email'))