fork download
  1. #include <stdio.h>
  2. int main()
  3. {
  4. int a = 10; // just a variable, start at 10
  5. int i; // loop increment
  6.  
  7. for (i = 1; i < 10; i = i + 2)
  8. {
  9.  
  10. a += 5;
  11. printf ("In Loop: i = %i, a = %i\n" , i, a); // print final values
  12. continue;
  13. a += 100; // ignore this statement, it will never be executed
  14.  
  15. } // end of loop
  16.  
  17. printf ("after the loop\n"); // first executable statement after the loop
  18. printf ("Final Values: i = %i, a = %i\n", i, a); // print final values
  19.  
  20. return (0);
  21.  
  22. } // end main
Success #stdin #stdout 0s 5312KB
stdin
Standard input is empty
stdout
In Loop: i = 1, a = 15
In Loop: i = 3, a = 20
In Loop: i = 5, a = 25
In Loop: i = 7, a = 30
In Loop: i = 9, a = 35
after the loop
Final Values: i = 11, a = 35