what are abstract classes and how they impliment , with
example

Answer Posted / manoj kumar

abstract class is a class which may or may not contain
abstract method.
abstract class can,t be instantiated i.e. we can,t
create object of an abstract class.
abstract class can be subclasses .
abstract class is a class which is declared abstract.
if any class contain abstract method then it can be
declared abstract.
example
abstract class{

abstract public void display();//abstract method
}
abstract method is method which is declared but not
implemented i.e. without braces followed by semicolon.

Is This Answer Correct ?    8 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is abstraction in oop?

634


What is overriding vs overloading?

584


What is the renewal class?

2167


Why do pointers exist?

660


Which language is not a true object oriented programming language?

642






officer say me - i am offered to a smoking , then what can you say

1581


What is difference between polymorphism and inheritance?

617


What is oops with example?

565


Why can't we have instance(stack) of a class as a member of the same class like eg.Class A{A obj;} as we can have self refential pointer

1621


What is inheritance write a program to show use of inheritance?

612


Explain virtual inheritance?

682


What is the important feature of inheritance?

635


What is stream in oop?

841


What is abstraction example?

624


What are main features of oop?

633