Skip to content

Commit e22892b

Browse files
committed
issue 49
1 parent 289a31e commit e22892b

1 file changed

Lines changed: 18 additions & 18 deletions

File tree

‎koans/src/java8/AboutMultipleInheritance.java‎

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -5,33 +5,33 @@
55
import static com.sandwich.util.Assert.assertEquals;
66
import static com.sandwich.koan.constant.KoanConstants.__;
77

8-
interface Human{
9-
default String sound(){
10-
return "hello";
8+
public class AboutMultipleInheritance {
9+
10+
interface Human{
11+
default String sound(){
12+
return "hello";
13+
}
1114
}
12-
}
1315

14-
interface Bull{
15-
default String sound(){
16-
return "moo";
16+
interface Bull{
17+
default String sound(){
18+
return "moo";
19+
}
1720
}
18-
}
1921

20-
class Minotaur implements Human, Bull{
21-
//both interfaces implement same default method
22-
//has to be overridden
23-
@Override
24-
public String sound(){
25-
return Bull.super.sound();
22+
class Minotaur implements Human, Bull{
23+
//both interfaces implement same default method
24+
//has to be overridden
25+
@Override
26+
public String sound(){
27+
return Bull.super.sound();
28+
}
2629
}
27-
}
28-
29-
public class AboutMultipleInheritance {
3030

3131
@Koan
3232
public void multipleInheritance(){
3333
Minotaur minotaur = new Minotaur();
3434
assertEquals(minotaur.sound(), __);
3535
}
3636

37-
}
37+
}

0 commit comments

Comments
 (0)