OFFSET
1,1
COMMENTS
Inspired by a discussion on the math-fun list on April 18, 2012 by James R. Buddenhagen.
PROG
(Haskell)
oddDigits 0 = True
oddDigits n = let (q, r) = quotRem n 10
..............in (odd r) && oddDigits q
oddSet 0 = []
oddSet 1 = [1, 3..9]
oddSet k = [n | i <- [1, 3..9], x <- oddSet (k-1), let n = i*10^(k-1) + x,
...............oddDigits((n^3) `mod` 10^k)]
main = putStrLn $ map (length . oddSet) [1..]
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Victor S. Miller, Apr 18 2012
STATUS
approved