|
|
A029740
|
|
Odd numbers with distinct digits.
|
|
4
|
|
|
1, 3, 5, 7, 9, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31, 35, 37, 39, 41, 43, 45, 47, 49, 51, 53, 57, 59, 61, 63, 65, 67, 69, 71, 73, 75, 79, 81, 83, 85, 87, 89, 91, 93, 95, 97, 103, 105, 107, 109, 123, 125, 127, 129, 135, 137, 139, 143, 145, 147, 149, 153, 157
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
COMMENTS
|
Maximum term is 9876543201. Next higher number with distinct digits is 9876543210. - Alonso del Arte, Jan 09 2020
|
|
LINKS
|
|
|
MATHEMATICA
|
Select[Range[1, 199, 2], Max[DigitCount[#]] == 1 &] (* Harvey P. Dale, Jan 12 2019 *)
|
|
PROG
|
(Scala) def hasDistinctDigits(n: Int): Boolean = {
val numerStr = n.toString
val digitSet = numerStr.split("").toSet
numerStr.length == digitSet.size
}
(Python) # generates full sequence
from itertools import permutations
afull = sorted(set(int("".join(p)) for d in range(1, 11) for p in permutations("0123456789", d) if p[0] != "0" and p[-1] in "13579"))
|
|
CROSSREFS
|
Cf. A029741 (even version). Union of that sequence with this sequence gives A010784.
|
|
KEYWORD
|
nonn,fini,base
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|