OFFSET
1,2
LINKS
Reinhard Zumkeller, Table of n, a(n) for n = 1..10000
PROG
(Haskell)
import Data.List ((\\), nub)
a037396 n = a037396_list !! (n-1)
a037396_list = filter f [1..] where
f x = null $ nub (ds 5 x) \\ nub (ds 9 x)
ds b x = if x > 0 then d : ds b x' else [] where (x', d) = divMod x b
-- Reinhard Zumkeller, May 30 2013
(PARI) is(n)=#setminus(Set(digits(n, 5)), Set(digits(n, 9)))==0 \\ Charles R Greathouse IV, Feb 11 2017
CROSSREFS
KEYWORD
nonn,base
AUTHOR
STATUS
approved