Responsibility is the work that has been assigned to the class. In the SOLID set of principles, the S stands for Single Responsibility Principle (SRP). When applied to a class, SRP states that the class must only work on a single aspect of the feature being implemented. The responsibility of that single aspect should be fully encapsulated within the class. Therefore, you should never apply more than one responsibility to a class.
Let's look at an example to understand why:
public class MultipleResponsibilities()
{
public string DecryptString(string text,
SecurityAlgorithm algorithm)
{
// ...implementation...
}
public string EncryptString(string text,
SecurityAlgorithm algorithm)
{
// ...implementation...
}
public string ReadTextFromFile(string filename)
{
// ...implementation...
}
public string SaveTextToFile(string text, string filename)
...