1 2 3 4 5 6 7 8 9 10 11 12

The following advice on C++ programming is paraphrased from the work "On to C++" by Patrick Winston, Addison Wesley, 1995

Procedure abstraction puts details of computations inside functions.

Your programs benefit from procedure abstraction by being:

(a) (b) (c) (d) (e) (f)

easier to re-use easier to read easier to debug easier to extend easier to improve easier to adapt

If you want to make a function with a class-object parameter into a member function, then define the function inside the class definition (as you would an ordinary function) and eliminate the class-object parameter from both the parameter list and from the member variable reference. See Reverse.cc and Arraystack.h of Vstacks example

24-Mar-98

Page 1

TAM/C201