// This program goes into an infinite loop
// You need to figure out why
public class Infinite {
public static void main (String [] args) {
int n = 1, sum = 0;
// the loop computes the sum of all odd numbers <= 20
while (n <= 20) {
sum = sum + n;
}
System.out.println("sum = " + sum);
}
}