A class should not be forced to implement methods it does not use.
You should be able to add a new payment method (e.g., Stripe) by creating a new class that extends a base interface, rather than rewriting your existing checkout logic. L: Liskov Substitution Principle (LSP)
In Laravel or standard PHP, a UserController should only handle HTTP requests. It should not directly calculate payroll or send emails; those tasks belong in separate services or observers. O: Open-Closed Principle (OCP)
Classes should be open for extension but closed for modification.
The acronym represents five essential rules for high-quality software architecture: S: Single Responsibility Principle (SRP)