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!)
A258188 Smallest multiple of 7 not appearing earlier that ends with n. 4
21, 42, 63, 14, 35, 56, 7, 28, 49, 210, 511, 112, 413, 714, 315, 616, 217, 518, 119, 420, 721, 322, 623, 224, 525, 126, 427, 728, 329, 630, 231, 532, 133, 434, 735, 336, 637, 238, 539, 140, 441, 742, 343, 644, 245, 546, 147, 448, 749, 350, 651, 252, 553, 154 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
a(10*n) = 10*a(n).
The sequence is a permutation of the positive multiples of 7. - Vladimir Shevelev, May 24 2015
A258329(n) = a(n) / 7 is a permutation of the positive integers. - Reinhard Zumkeller, May 27 2015
LINKS
MATHEMATICA
a[n_] := a[n] = For[k = 7, True, k = k + 7, If[Divisible[k - n, 10^IntegerLength[n]] && FreeQ[Array[a, n-1], k], Return[k]]]; Array[a, 54] (* Jean-François Alcover, Feb 07 2018 *)
PROG
(Haskell)
import Data.List (isPrefixOf, delete)
a258188 n = a258188_list !! (n-1)
a258188_list = f 1 $ tail $ zip
a008589_list $ map (reverse . show) a008589_list where
f x ws = g ws where
g ((u, vs) : uvs) = if isPrefixOf xs vs
then u : f (x + 1) (delete (u, vs) ws) else g uvs
xs = reverse $ show x
CROSSREFS
Sequence in context: A260749 A040420 A192130 * A037978 A089059 A114384
KEYWORD
nonn,base
AUTHOR
STATUS
approved

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 01:35 EDT 2024. Contains 371964 sequences. (Running on oeis4.)