[8일차] 객체지향 프로그래밍(다형성), 예외, 매직메서드
다중 상속(7일차)에 이어서# MRO (Method Resolution Order)다중 상속 시 메서드나 속성을 찾는 순서를 정의하는 규칙클래스 간의 메서드 충돌을 해결# stack에 쌓이는 것을 "print ___ 끝" 으로 확인할 수 있음class Base: def hello(self): print("Base") class Clean(Base): def hello(self): print("Clean") super().hello() print("Clean 끝") class Pack(Base): def hello(self): print("Pack") super().hello() ..
2026.05.29