OFFSET
1,1
LINKS
Reinhard Zumkeller, Table of n, a(n) for n = 1..10000
MATHEMATICA
Select[Range[350], SequenceCount[IntegerDigits[#], {___, x_, x_, ___}]>0&] (* The program uses the SequenceCount function from Mathematica version 10 *) (* Harvey P. Dale, May 14 2016 *)
PROG
(Haskell)
import Data.List (elemIndices)
a171901 n = a171901_list !! n
a171901_list = elemIndices 0 a196368_list
-- Reinhard Zumkeller, Oct 29 2001
(Python)
def is_ok(n):
s = str(n)
return any(s[i] == s[i - 1] for i in range(1, len(s)))
A171901_list = [n for n in range(400) if is_ok(n)] # Chai Wah Wu, Feb 14 2019
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Reinhard Zumkeller, Feb 07 2010
STATUS
approved