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

@ -26,12 +26,13 @@ Here, the last character sets the teleprinter to figures.]
[4] PF PF [1st difference for n^2]
[Constants]
[2024-12-25 Load time: clear each 35-bit constant, including sandwich bit]
T6#ZPF T8#ZPF T10#ZPF T12#ZPF
[Then resume normal loading at first 35-bit constant]
T6Z
[6] P64F PF [2nd difference for n^2, i.e. 128]
[8] P4F PF [1st difference for n, i.e. 8]
T10#Z PF T10Z [clears sandwich digit between 10 and 11;
cf. Wilkes, Wheeler & Gill, 1951, pp 110, 141-2]
[10] #1760F V2046F [-1000000]
T12#Z PF T12Z [clears sandwich digit between 12 and 13]
[12] Q1728F PD [269696]
[14] &F [line feed]
[15] @F [carriage return]

View file

@ -1,6 +1,14 @@
Def Long k=1000000, T=269696, n
long long k=1000000, T=269696, n
boolean first=true
Document doc$
n=Sqrt(269696)
For n=n to k {
If n^2 mod k = T Then Exit
If n^2&& mod k = T Then
doc$=format$("The "+if$(first->"smallest", "next")+" number whose square ends in {0} is {1}, Its square is {2}", T, n, n**2&&)+{
}
first=false
refresh
end if
}
Report format$("The smallest number whose square ends in {0} is {1}, Its square is {2}", T, n, n**2)
clipboard doc$
report doc$

View file

@ -0,0 +1,9 @@
//the smallest positive integer whose square ends in the digits 269,696
## var k:=269696;
var n:=trunc(sqrt(k));(* Start with n *)
if n mod 2<>0 then n-=1;(* n:=n-1 *)
repeat
n += 2 (* Increase n by 2. n:=n+2 *)
until (n * n) mod 1000000 = 269696;
$'The smallest positive integer is {n} whose square ends in {k}'.println;
$'{n}² = {n*n}'.println;