What is Default method in Interface ?
Default method is introduced in java 8 before java 8 we were able to only provide abstract methods but now we can write default methods as well and provide default implementatio in interface it self.
So that any other classes which are implementing that interface won't impacted. If any class want to provide there own implementation then they can override the default method and provide there own implementation in class.
Why Default Method is introduced i java 8 ?
What is default method in Java?
What does default method mean?
What is default method and static method in Java?
How do you write a default method?
Can we have default method in class?
Why default method is introduced?
Can default method be overridden?
#functionalinterface #java8 #javainterviewquestions #java8features