Skip to main content
Journey Uncommon Logo
JourneyUncommon
mediumPythonclassmethod vs staticmethodSingle-choice MCQ

A base class defines a classmethod factory `make` that returns `cls(...)`. When called as `Sub.make(...)` on a subclass, what is the type of the returned object?

class Base: def __init__(self, v): self.v = v @classmethod def make(cls, v): return cls(v) class Sub(Base): pass obj = Sub.make(5)