login
A343725
a(n) is the largest n-digit square with all digits even.
3
4, 64, 484, 8464, 88804, 868624, 8880400, 86862400, 888040000, 8880800644, 88864802404, 888868068804, 8886826042084, 88886806880400, 888686062262244, 8888680688040000, 88868606226224400, 888868068804000000, 8888600480200862404, 88886806880400000000
OFFSET
1,1
LINKS
PROG
(Python 3.8+)
from math import isqrt
def A343725(n):
m = isqrt(8*(10**i-1)//9)
m -= m % 2
k = m**2
s = set('02468')
while not set(str(k)) <= s:
m -= 2
k -= 4*(m+1)
return k # Chai Wah Wu, May 20 2021
CROSSREFS
Sequence in context: A169801 A103751 A053959 * A195800 A224446 A128782
KEYWORD
nonn,base
AUTHOR
Jon E. Schoenfield, May 19 2021
STATUS
approved