OFFSET
2,1
COMMENTS
Let d = n - number of digits in n. Question: Is n*10^d -1 always a squarefree number?
If 9 divides n-1, then 9 divides n*10^d-1, so it is not squarefree. - Enrique Pérez Herrero, Apr 15 2015
MAPLE
a:= proc(n) local d, k;
d:= ilog10(n)+1;
for k from (n+1)*10^(n-d)-1 by -1 do
if numtheory:-issqrfree(k) then return(k) fi
od
end proc:
seq(a(n), n=2..50); # Robert Israel, Apr 17 2015
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Amarnath Murthy, Nov 08 2002
EXTENSIONS
More terms from Sascha Kurz, Jan 04 2003
STATUS
approved