Advertisement
Guest User

Untitled

a guest
May 22nd, 2019
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.25 KB | None | 0 0
  1. public class SampleExtendsOverload2 {
  2.  
  3. public static void main(String[] args) {
  4. C obj = new C();
  5. }
  6. }
  7.  
  8. class A {
  9. A(){System.out.println("A");}
  10. }
  11.  
  12. class B extends A{
  13. B(){System.out.println("B");}
  14. }
  15.  
  16. class C extends B{
  17. C(){System.out.println("C");}
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement