What are virtual functions in c++, C/C++ Programming

A virtual function permits derived classes to replace the implementation given by the base class. The compiler makes sure the replacement is always known as whenever the object in question is actually of the derived class, even if the object is accessed by a base pointer rather than a derived pointer. This permits algorithms in the base class to be replaced in the derived class, even if users don't know about the derived class.                

 

 

Posted Date: 4/8/2013 5:52:24 AM | Location : United States







Related Discussions:- What are virtual functions in c++, Assignment Help, Ask Question on What are virtual functions in c++, Get Answer, Expert's Help, What are virtual functions in c++ Discussions

Write discussion on What are virtual functions in c++
Your posts are moderated
Related Questions
Define Static Storage Class in C Programming? The Static declarations have distinct and important uses. This allows the local variable to keep its previous value when the block

(a) Verify the values of the resistors with the following colour coding: (i) red-red-orange-silver (ii) orange-orange-black-blue-green (b) What is the value of a resistor

exemples of many to many

Hi is there any chance to get assignment for fresher tutor

Operation on list - c++ program: Write a program in c to Insert value on list and list iteration. typedef struct item *node_ptr; struct item {                   int e


1. The main program must be in a file called A4.cpp 2. The data must be read in from a data file.  The user must enter the filename.  A sample data file will be provided on Mood

Operators The variables, which are declared and explained, are the operands, which are operated upon by the operators. Operators specify what operations are to be performed on

Write a C program to compute the factorial of  5 i.e. 1x2x3x4x5 etc Write a C program to calculate the output Y for a given value of X for the following formula.       Y=X 2

Many human diseases could be controlled by the knowledge of the gene’s structure and pattern. The human gene could be represented by four nucleotides. Each nucleotide is represente