Move 1988-2004 entries into subdirs

We we move 1988-2004 entries from all of a year's winning entries
in a single directory to each winner being in their own sub-directory
under the given year directory.
This commit is contained in:
Landon Curt Noll committed 2022-09-18 23:37:49 -07:00
1 parent 1e82e8aa3e
commit d2a42f42e8
478 files changed

No files matched your search

+37
View File
@@ -0,0 +1,37 @@
int m = 754974721, N, t[1 << 22], a, *p, i, e = 1 << 22, j, s, b, c, U;
f (d)
{
for (s = 1 << 23; s; s /= 2, d = d * 1LL * d % m)
if (s < N)
for (p = t; p < t + N; p += s)
for (i = s, c = 1; i; i--)
b = *p + p[s], p[s] = (m + *p - p[s]) *
1LL * c % m, *p++ = b % m, c = c * 1LL * d % m;
for (j = 0; i < N - 1;)
{
for (s = N / 2; !((j ^= s) & s); s /= 2);
if (++i < j)
a = t[i], t[i] = t[j], t[j] = a;
}
}
main ()
{
*t = 2;
U = N = 1;
while (e /= 2)
{
N *= 2;
U = U * 1LL * (m + 1) / 2 % m;
f (362);
for (p = t; p < t + N;)
*p++ = (*p * 1LL ** p % m) * U % m;
f (415027540);
for (a = 0, p = t; p < t + N;)
a += (6972593 & e ? 2 : 1) ** p, *p++ = a % 10, a /= 10;
}
while (!*--p);
t[0]--;
while (p >= t)
printf ("%d", *p--);
}
+38
View File
@@ -0,0 +1,38 @@
Most Specific Output:
Fabrice Bellard
451 chemin du mas de Matour
34790 Grabels
France
http://www.enst.fr/~bellard
Judges' Comments:
To build:
make bellard
To run:
./bellard
This code is an nice compact example of a Modular Fast Fourier Transform.
While its output is very specific, the internal FFT has a wide variety
of uses.
Can you modify this code to produce primes such as 23523*2^70000-1,
48594^65536+1 or 6917!-1?
Selected Author's Comments:
This program prints the biggest known prime number (2^6972593-1)
in base 10. It requires a few minutes. It uses a Modular Fast
Fourier Transform to compute this number in a reasonable amount
of time (the usual method would take ages !).
The program uses >= 64 bit 'long long' type. It should run on any
system with a gcc compiler.