Define pure virtual function or abstract class?, C/C++ Programming

Define pure virtual function or abstract class?



Posted Date: 3/16/2013 2:42:09 AM | Location : United States

A: While you de_ne only function prototype in a base class with no implementation & do the total implementation in derived class. This base class is called as abstract class & client won''t capable to instantiate an object by using this base class. You can develop a pure virtual function or

abstract class this way.. class Boo


void foo() = 0;


Boo MyBoo; // compilation error


Posted by | Posted Date: 3/16/2013 2:42:20 AM

Related Discussions:- Define pure virtual function or abstract class?, Assignment Help, Ask Question on Define pure virtual function or abstract class?, Get Answer, Expert's Help, Define pure virtual function or abstract class? Discussions

Write discussion on Define pure virtual function or abstract class?
Your posts are moderated
Related Questions
Explain Operator Overloading It is one type of Polymorphism, an significant feature of object-oriented programming .Polymorphism means one thing having many forms, i.e. here an

Using Figure 10.2 as a model, illustrate the result of each operation in the sequence ENQUEUE.Q; 4/, ENQUEUE.Q; 1/, ENQUEUE.Q; 3/, DEQUEUE.Q/, ENQUEUE.Q; 8/, and DEQUEUE.Q/ on an i

By pressing ‘6’ (i.e. key’6’ one time) on the keypad, the mobile shows ‘m’ on display screen in write text message area

write a c++ program for minimum shelf downloads

It is a feature in C++ to reduce name collisions in the global name space. This namespace keyword assigns a separate name to a library that allows other libraries to use the simila

External Variables Different functions of the similar program can be written in different source files and can be compiled together. The scope of a global variable is not limit

At a shop of marbles, packs of marbles are prepared. Packets are named A, B, C, D, E …….. All packets are kept in a VERTICAL SHELF in random order. Any numbers of packets with thes

complex coding with structure and file handling

A string S is said to be "Super ASCII", if it contains the character frequency equal to their ascii values. String will contain only lower case alphabets (''a''-''z'') and the asci

Pointers are just numbers, representing addresses in memory. You can add to and subtract from pointers, for instance. It is pretty easy to make mistakes with pointer math, however,