What is the Interface Segregation Principle (ISP) in Java?
ISP suggests that all interfaces should be kept small so they are easier to use and understand.
Thatâ€™s incorrect. ISP is not just about making interfaces smaller, but about ensuring that they contain only methods relevant to the implementing classes.
Can you describe the difference between a general-purpose interface and a segregated interface?