1. What is polymorphism? What is static and dynamic polymorphism
2. What is vitual functions?
3. What is vtable and vptr?
4. What are the type of design pattern? Explain it. Tell about subtype of that.
5. Which design pattern you have used in you project? How will you decide which design pattern to use where?
6. What is singleton design.
7. Write small fun for operator overloading for + operator
8. Why we use const in prototype of operator overloading?
9. class test {
int funct( void ) const;
};
what it will return?
->There is a pointer to the object for which a function is called known as the 'this' pointer. By default the type of 'this' is X *const ( a constant pointer). The const keyword changes the type to const X *const ( a constant pointer to constant data ).
10. Difference betn vector and list? How will u decide which one to use
11. You have a class called Math which having 2 virtual fun add(), sub(). How many vtable will be created for this class and how it looks like??
What we store in vtable?