what are abstract classes and how they impliment , with
example
Answers were Sorted based on User's Feedback
Answer / 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 |
A class with atleast one pure virtual function is called
abstract class.It cant be instatiated.It can be used as a
base class for other classes. The class derived from an
abstract base class can be instantiated,provided it should
implement the abstract base class pure virtual function.
| Is This Answer Correct ? | 7 Yes | 0 No |
What is polymorphism? Explain with an example.
What is a function in oop?
what is a ststic variable and stiticfunction briefly explain with exmple and in which case we use
Can an interface inherit a class?
Example for 4 pillar of oops like, Inheritance,Poly,Abstraction,Encabsulation ?
What does and I oop and sksksk mean?
When is an object created and what is its lifetime?
What are oops methods?
What is polymorphism explain its types?
what is code for call by value and call by reference?
explain dynamic binding by drowing
Define a class to represent a bank account. Include the following members: Data Members: Name of the Depositor Account Number Type of Account Balance amount in the account Member Functions: To assign the initial values. To deposit an account. To withdraw an amount after checking the balance. Write a C++ main program to display account number, name and balance.