I apologize for my stupid question, but ... let's say I have these classes:
class A():
msg = 'hehehe'
class B(A):
msg = 'hohoho'
class C(B):
pass
and instance B or C. How to get msg variable from parent class object through this instance? I tried this:
foo = B()
print super(foo.__class__).msg
but received a message: "TypeError: super () argument 1 must be a type, not classobj."
source
share