1 /* 2 * Created on Dec 27, 2004 3 * 4 * TODO To change the template for this generated file go to 5 * Window - Preferences - Java - Code Style - Code Templates 6 */ 7 8 /** 9 * @author jlhotak 10 * 11 * TODO To change the template for this generated type comment go to 12 * Window - Preferences - Java - Code Style - Code Templates 13 */ 14 public class LoopInvariant { 15 16 public static void main(String[] args) { 17 int x = 9; 18 int z = 10; 19 int y = 8; 20 int k = 0; 21 int m = 0; 22 23 for (int i = 0; i < 100; i++){ 24 y = x + z; 25 System.out.println(y); 26 k = x + i; 27 28 int j = 9; 29 m = j + 1; 30 } 31 } 32 } 33