OFFSET
1,2
COMMENTS
Union of A011557 and A052216. I.e., numbers with digital sum 1 or 2. - David A. Corneth, Aug 10 2022
MATHEMATICA
Select[Range[1, 10000001], Plus @@ IntegerDigits[#] < 3 &] (* Amiram Eldar, Aug 10 2022 *)
PROG
(PARI) isok(k) = my(s=sumdigits(k)); numdiv(s) == s; \\ Michel Marcus, Aug 10 2022
(PARI) is(n) = my(s = sumdigits(n)); s == 1 || s == 2 \\ David A. Corneth, Aug 10 2022
(Python)
from itertools import count, islice
def agen():
for i in count(0):
yield from [10**i] + [10**i + 10**j for j in range(i+1)]
print(list(islice(agen(), 37))) # Michael S. Branicky, Aug 10 2022
CROSSREFS
KEYWORD
nonn,easy,base
AUTHOR
Ctibor O. Zizka, Aug 10 2022
STATUS
approved