What is abstrac class?where is it use?
Answers were Sorted based on User's Feedback
Answer / gp
Class which cannot be initiated is an abstract class.
You can make a class abstract by declaring a pure virtual method inside the class. For example:
class base
{
void func()=0;
};
void main()
{
base b;
}
Now you cannot instantiate base class.
The class which inherits this base class will also become abstract unless you define a body of the func() method in inherited class.
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / vijaya lakshmi
abstrac class always said to algorithm. Bacause you
ara writing program before explain a program in algorithm
| Is This Answer Correct ? | 0 Yes | 4 No |
What is overloading in oop?
What is inheritance and how many types of inheritance?
What is the use of fflush(stdin) in c++?
In c++ there is only virtual destructors, no constructors. Why?
What are the three parts of a simple empty class?
Why do we use inheritance?
Which is the parameter that is added to every non-static member function when it is called?
What is difference between inheritance and polymorphism?
Why is destructor used?
what is overloading
There are 2 classes defined as below public class A { class B b; } public class B { class A a; } compiler gives error. How to fix it?
What is static modifier?