3 static int m = 754974721;
9 //static int e = 1 << 22;
10 static int e = 1 << 10;
19 for (s = 1 << 23; s; s /= 2, d = d * 1L * d % m) {
21 for (p = t; p < t + N; p += s) {
22 for (i = s, c = 1; i; i--) {
23 b = *p + p[s], p[s] = (m + *p - p[s]) *
24 1L * c % m, *p++ = b % m, c = c * 1L * d % m;
29 for (j = 0; i < N - 1;)
31 for (s = N / 2; !((j ^= s) & s); s /= 2)
35 a = t[i], t[i] = t[j], t[j] = a;
46 U = U * 1L * (m + 1) / 2 % m;
48 for (p = t; p < t + N;)
49 *p++ = (*p * 1L * *p % m) * U % m;
52 for (a = 0, p = t; p < t + N;) {
53 a += (0x6A64B1 & e ? 2 : 1) * *p;
67 printf ("Checksumme = %d\n", qs);