Home Segments Index Top Previous Next

21: Mainline

To relieve the sample program of part of its catatonia, you can provide statements that tell the C++ compiler that you want the results of the multiplication to be displayed, as in the following revised program:

#include  
main ( ) { 
  cout << "The volume of the box car is "; 
  cout << 11 * 9 * 40; 
  cout << endl; 
} 

The revised program introduces several concepts and syntactical markers, and forces the introduction of the line #include <iostream.h>. Accordingly, you need to zoom in, and to look at the revised program piece by piece.