login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A112889 a(n) is the least nonnegative integer in base 10 containing n zeros that is divisible by n. 20

%I #16 Jul 10 2023 17:40:34

%S 0,100,3000,10000,100000,3000000,70000000,100000000,9000000000,

%T 10000000000,1000000000010,3000000000000,100000000000004,

%U 700000000000000,3000000000000000,10000000000000000,1000000000000000002,9000000000000000000,100000000000000000090

%N a(n) is the least nonnegative integer in base 10 containing n zeros that is divisible by n.

%H Robert Israel, <a href="/A112889/b112889.txt">Table of n, a(n) for n = 1..993</a>

%F a(n) = n*A112890(n).

%e a(3) = 3000 because 3000 contains 3 zeros and is divisible by 3.

%p f:= proc(n) local d,x,y,z,d2,v;

%p for x from 1 to 9 do if x*10^n mod n = 0 then return x*10^n fi od;

%p for y from 1 to 9 do

%p for d from 0 to n do

%p for x from 1 to 9 do

%p v:= y*10^(n+1) + x*10^d;

%p if v mod n = 0 then return v fi;

%p od od od;

%p for z from 1 to 9 do

%p for d from 2 to n+1 do

%p for y from 1 to 9 do

%p for d2 from 0 to d-1 do

%p for x from 1 to 9 do

%p v:= z*10^(n+2) + y*10^d + x*10^d2;

%p if v mod n = 0 then return v fi;

%p od od od od od;

%p FAIL

%p end proc:

%p f(1):= 0:

%p map(f, [$1..50]); # _Robert Israel_, Jul 10 2023

%Y Cf. A112890-A112898, A112900-A112905, A112907-A112910.

%K base,nonn

%O 1,2

%A _Ray G. Opao_, Oct 05 2005

%E Extended by _Ray Chandler_, Oct 09 2005

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 13:32 EDT 2024. Contains 371971 sequences. (Running on oeis4.)