c1 -- super class
c2 and c3 extends from c1
c4 extends from c2 and c3.
what you have stated is a diamond case, which cannot be accomplished in
java
However, can be accomplished in this way, but the following cannot be said as diamond case because it doesn't have the problem of dianmond case
Scenario 1:
interface i1 {}
interface i2 extends i1 {}
interface i3 extends i1 {}
interface i4 extends i2,i3 {}
Scenario 2:
interface i1 {}
interface i2 extends i1 {}
interface i3 extends i1 {}
class c4 implements i2,i3 {}
Scenario 3:
interface i1 {}
interface i2 extends i1 {}
class c3 implements i1 {}
class c4 extends c3 implements i2 {}
Scenario 4:
interface i1 {}
class c2 implements i1 {}
interface i3 extends i1 {}
class c4 extends c2 implements i3 {}