What is the difference between Single Responsibility Principle and Separation of Concerns?
I tried to draw a comparison between Separation of concerns(SoC) and Single Responsibility Principle(SRP).
Differences
The SRP is at the class level, but SoC is in each computer program, abstraction ... or sometimes architectural level.
The SRP is about the quality of (how not what) dividing your domain into cohesive classes which have just one responsibility (one reason to change). In other side, SoC is a design principle for separating a context into distinct sections, such that each section addresses a separate concern(what not how), as there are a lot of tools (for example classes, functions, modules, packages, ...) to reach this goal different levels.
The concept of SRP is based on the cohesion (high cohesion), whereas SoC is close to Molecularity, divide and conquer (D&C), ... in each level of abstraction.
SoC is a good design principle to cope complexity, such as abstraction whereas to reach single responsible classes you can use SoC principle as a great solution. As, a way to know that a class has more than one responsibility is if you can extract another responsibility(concern) from that class.
Similarities