You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The base class can be replaced by its subclass without changing behavior:
EuroMoney and UAHMoney are subclasses of BaseMoney, and any IMoney object can be used without changing the logic. If BaseMoney is removed, the code will still work, but common methods (SetParts(), ToString()) would need to be duplicated in each class.
6. I - Interface Segregation Principle (SOLID)
Interfaces are clearly divided and do not contain unnecessary methods: