Once again we are into a completely new topic with terminology which will be new to you. If you are new to object oriented programming, you should follow along in this chapter very carefully because every attempt has been made to define every detail of this new and somewhat intimidating topic. One term which must be defined is polymorphism , a rather large word that simply means similar when used in the context of object oriented programming.
Objects are polymorphic if they have some similarities but are still somewhat different.
We will see how it is used in the context of object oriented programming as we proceed through this chapter. We have already studied operator overloading and function overloading in this tutorial, and they are a subtle form of polymorphism since in both cases, a single entity is used to refer to two or more things. The use of virtual functions can be a great aid in programming some kinds of projects as you will see in these two chapters. Programming exercises Summary A simple program with inheritance Examine the example program named virtual1.cc for the basic program outline we will use for all discussion in this chapter. Since this program has nothing to do with virtual functions, the name may be somewhat misleading.