OFFSET
1,1
COMMENTS
The number of terms less than 10^k: 0, 5, 64, 395, 2406, 13417, 78268, ..., . - Robert G. Wilson v, Apr 04 2011
LINKS
Reinhard Zumkeller, Table of n, a(n) for n = 1..1000
EXAMPLE
132 is divisible by 1, 3 & 2.
MATHEMATICA
f[x_, y_] := (y == Take[x, Min[Length@ y, Length@ x]]); g[{}, _] := True; g[LL_, DD_] := Module[{a = Select[DD, f[LL, IntegerDigits@ #] &]}, Or @@ Map[ g[ Drop[ LL, Length@ IntegerDigits@ #], Complement[DD, {#}]] &, a]]; fQ[n_] := g[IntegerDigits@ n, Most@ Divisors@ n]; Select[ Range@ 2000, fQ] (* Robert G. Wilson v, Apr 04 2011 *)
PROG
(Haskell)
import Data.List (permutations, subsequences, isInfixOf)
a050480 n = a050480_list !! (n-1)
a050480_list = filter chi [2..] where
chi x = xs `elem` (map concat $ choices divs) where
choices = concat . (map permutations) . subsequences
divs = filter (`isInfixOf` xs)
$ map show $ filter ((== 0) . mod x) [1..a032742 x]
xs = show x
-- Reinhard Zumkeller, Apr 04 2011
CROSSREFS
KEYWORD
base,easy,nice,nonn
AUTHOR
Erich Friedman, Dec 24 1999
EXTENSIONS
Offset adjusted by Reinhard Zumkeller, Apr 04 2011
STATUS
approved