We all know about the diamond problem regarding multiple inheritance -
A
/ \\
B C
\\ /
D
This problem describe an ambiguous
With default methods in interface introduced in Java 8, multiple inheritance related problem may arise, there are 3 scenarios -
1- If implementing class overrides the default method and provides its own functionality for the default method then the method of the class takes priority over the interface default methods.
2-When class implements both interfaces and both have the same default method, also the class is not overriding that method then the error will be thrown.
3-In case when an interface extends another interface and both have the same default method, the inheriting interface default method will take precedence.
read more about it here.