Advertisement
waltermilner

Untitled

Oct 9th, 2015
262
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.31 KB | None | 0 0
  1. abstract class A {
  2.  
  3.   public void abc() {
  4.     System.out.println("Class A");
  5.   }
  6. }
  7.  
  8. interface B {
  9.  
  10.   default void abc() {
  11.     System.out.println("Interface B");
  12.   }
  13. }
  14.  
  15. public class Test extends A implements B {
  16.  
  17.   public static void main(String[] args) {
  18.     Test t = new Test();
  19.     t.abc();
  20.   }
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement