You have one base class virtual function how will call that
function from derived class?
Answer Posted / swetcha
class a
{
public virtual int m()
{
return 1;
}
}
class b:a
{
public int j()
{
return m();
}
}
| Is This Answer Correct ? | 4 Yes | 4 No |
Post New Answer View All Answers
How to handle exception in c++, For example in a functions i am assigning memory to some variables and also in next instructions in am dividing one variable also. If this functions generates a error while allocating memory to those variable and also while dividing the variable if i divide by zero then catch block how it will identify that this error has cone from perticular instruction
Can you explain polymorphism?
Please send ford technologies placement paper 2 my mail id
Why we use classes in oop?
What is oops concept with example?
Can an interface inherit a class?
Write a c++ program to display pass and fail for three student using static member function
INSTANCE FIELDS DECLARED private ARE ACCESSIBLE BY THE METHODS ONLY.CAN WE CHANGE THE private FIELD OF AN OBJECT IN A METHOD OF SOME OTHER OBJECT OF THE SAME CLASS?
What are the three parts of a simple empty class?
Explain the advantages of inheritance.
What is encapsulation and abstraction? How are they implemented in C++?
why reinterpret cast is considered dangerous?
What is meant by multiple inheritance?
What is object in oops?
what is different between oops and c++