A280824 Numbers with an even number of digits and with an even number of distinct digits.
10, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 1000, 1001, 1010
Offset: 1
Links
- Michael S. Branicky, Table of n, a(n) for n = 1..10000
- Eric Weisstein's World of Mathematics, Digit
- Index entries for 10-automatic sequences.
Programs
-
Maple
isA280824 := proc(n) if n < 10 then return false; end if; dgs := convert(n,base,10) ; if type(nops(dgs),'even') then type(nops(convert(dgs,set)),'even') ; else false; end if; end proc: # R. J. Mathar, Jan 17 2017
-
Mathematica
Select[Range[1010], Mod[Length[IntegerDigits[#1]], 2] == 0 && Mod[Length[Union[IntegerDigits[#1]]], 2] == 0 & ]
-
Python
def ok(n): s = str(n); return len(s)%2 == 0 == len(set(s))%2 print(list(filter(ok, range(1011)))) # Michael S. Branicky, Oct 12 2021
Comments