Monday, April 23, 2018

Can we have a constructor in an abstract class ?

  1. abstract class MyAbstractExe {
  2. MyAbstractExe() {
  3. System.out.println("yes we can have constructor in abstract class");
  4. }
  5. }
Yes ! we can have a constructor and there is no error.

No comments:

Post a Comment

Blueprint for self-improvement

To learn faster: Make the process fun To understand yourself : Write To understand the world better : Read To build deeper connection : Lis...