                              /* Chapter 3 - Program 3 - FORLOOP.C */
/* This is an example of a for loop */

#include <stdio.h>

int main()
{
int index;

   for(index = 0 ; index < 6 ; index = index + 1)
      printf("The value of the index is %d\n", index);

   return 0;
}



/* Result of execution

The value of the index is 0
The value of the index is 1
The value of the index is 2
The value of the index is 3
The value of the index is 4
The value of the index is 5

*/
