Category : C++ Source Code
Archive   : CPPTUT22.ZIP
Filename : CONCOM.CPP

 
Output of file : CONCOM.CPP contained in archive : CPPTUT22.ZIP
// Chapter 1 - Program 1

#include /* This is the stream definition file */

void print_it(const int data_value);

main()
{
const int START = 3; // The value of START cannot be changed
const int STOP = 9; // The value of STOP cannot be changed
volatile int CENTER = 6; /* The value of CENTER may be changed
by something external to this
program. */
int index; /* A normal C variable */

for (index = START ; index < STOP ; index++)
print_it(index);
} /* End of program */


void print_it(const int data_value)
{
cout << "The value of the index is " << data_value << "\n";
}




// Result of execution
//
// The value of the index is 3
// The value of the index is 4
// The value of the index is 5
// The value of the index is 6
// The value of the index is 7
// The value of the index is 8



  3 Responses to “Category : C++ Source Code
Archive   : CPPTUT22.ZIP
Filename : CONCOM.CPP

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/