int i; /* a variable, for example by the name of i, is needed */
for (i=1; i<=10; i++) {
/* code that needs to be repeated goes here */
}
Through this loop, the variable i successively gets assigned values from 1 to 10. In the first run through the loop i has the value 1, in the next run-through that value is increased to 2, then to 3, all the way up to and including 10.
How could you easily change the output of this program, so that instead of each line reading i x 7, where i is that incrementing variable, it prints as 7 x i? Or, what if you wanted to print a multiplication table for a different number, instead of 7? Try out some of these changes if you have time!