Open/Closed design principle explained with simple example
Open/Closed design principle is a software design principle which states that every module, class or function of a software should be open for extension but closed for modification. This design principle ensures any new functionality can be added via new classes which means minimum code changes required in existing classes.
Before going ahead we should know why do we need software design principle and what is software design principle.
(more…)