Single responsibility

IDFCNS-11
TitleFunctions should do precisely one thing well, and encapsulate a single idea.
PriorityStrongly recommended
Severity level4
DescriptionSingle responsibility principle : all sub-functions and most functions should do one thing very well, and encapsulate a single idea.
RationaleThe single responsibility principle makes code more readable, modular, and testable. Multi-purpose functions can often be split up into atomic units which are called on the input data in sequence. Functions should not try to be all things to all users.