Difference between abstract class with all method abstract and interface?
问题 I had an interview where interviewer asked me first what is the difference between abstract class with all the methods abstract and an interface. I replied that if it is required to inherit something in the future you will not be able to do it if you have already extended a class. Then, he stated that it was a situation where one would never have to extend any other class and you have to implement a contract. In this circumstance, which would be better, an abstract class or an interface? I