void print_int(int i) {}

// This function calculates n*n+n
void func(int n) {
  int i, k, j, d, r, z;

  k = n * n;
  d = k * 2;
  n += k;
  // k and d are dead
  r = n;
  // We going to mess with n, but we'll set
  // it back when we're done

  // Technically this whole loop could go away,
  // but that's another story
  for (i = 0; i < 30000000; i+=1) {
    // Swap some dead variables around
    k += d * k;
    d += k * d;

    // It almost looks like the value of k matters
    if (k <= d) {
        d += 1;
    }

    for (j = 0; j < 10; j+=1) {
      if (k > d) {
        k *= 2;
      }
    }
  } 

  n = r;
  print_int(n);
}

void main(void) {
  func(0);
  func(1);
  func(2);
}
