Data update

This commit is contained in:
Ingy döt Net 2025-02-27 18:35:13 -05:00
parent 8e4e15fa56
commit 72eb4943cb
1853 changed files with 35514 additions and 9441 deletions

View file

@ -0,0 +1,17 @@
##
function magic(n: biginteger) := n * (n * n + 1) div 2;
println('The first 20 magic constants:');
(1 + 2..22).Select(x -> magic(x)).Println;
println;
println('The 1,000th magic constant:',magic(1000 + 2),#10);
for var n := 1 to 20 do
begin
write('10^', n, ': ');
(1..maxint).Select(x -> biginteger(x))
.SkipWhile(x -> magic(x) < power(10bi, n))
.First
.Println;
end;