Difference between Abstract classes and Interfaces

Total Post:149

Points:1043
 1199  View(s)
Ratings:
Rate this:
Difference between  Abstract classes and Interfaces in Java


  1. Post:397

    Points:3117
    Re: Difference between Abstract classes and Interfaces

    Abstract classes

    1)An abstract class can have method body (non-abstract methods).
    2)An abstract class can have instance variables.
    3)An abstract class can have constructor.
    4)An abstract class can have static methods.
    5)You can extends one abstract class

    Interfaces
    Interface have only abstract methods.
    An interface cannot have instance variables.
    Interface cannot have constructor.
    Interface cannot have static methods.
    You can implement multiple interfaces.

    .

      Modified On Apr-09-2018 04:30:47 AM

Answer