C++ Classes, Constructors, and the Rule of Three
Design C++ classes with constructors, destructors, member initializer lists, and the Rule of Three and Five to manage resources safely.
5 posts.
Design C++ classes with constructors, destructors, member initializer lists, and the Rule of Three and Five to manage resources safely.
Design Java classes that hold state and behavior cleanly. Constructors, encapsulation, static vs instance, records, and the equals plus hashCode contract.
Use extends, super, and method overriding without painting yourself into a corner. When to inherit, when to compose, and how sealed types help.
Choose between interfaces and abstract classes with confidence. Default methods, sealed interfaces, functional interfaces, and concrete decision rules.
A practical introduction to Python classes — defining a class, __init__ and self, instance vs class attributes, methods, __repr__, and a first look at inheritance.