login
A377948
Numbers that have at least 1 repeated decimal digit and whose decimal digits are nondecreasing as place value decreases.
2
11, 22, 33, 44, 55, 66, 77, 88, 99, 111, 112, 113, 114, 115, 116, 117, 118, 119, 122, 133, 144, 155, 166, 177, 188, 199, 222, 223, 224, 225, 226, 227, 228, 229, 233, 244, 255, 266, 277, 288, 299, 333, 334, 335, 336, 337, 338, 339, 344, 355, 366, 377, 388, 399
OFFSET
1,1
COMMENTS
Intersection of A009994 and A109303.
Does not intersect either A009993 or A009995.
LINKS
Michael De Vlieger, Table of n, a(n) for n = 1..10938 (includes all numbers up to 7 digits long)
FORMULA
A178788(a(n)) = 0.
MATHEMATICA
Select[Range[10^6], And[CountDistinct[#] != Length[#], AllTrue[Differences[#], # >= 0 &]] &[IntegerDigits[#]] &]
(* More efficient program: *)
b = 10; mm = b - 1; nn = 14;
s = Table[Map[Position[#, 1][[All, 1]] &,
Permutations@ Join[ConstantArray[1, r], ConstantArray[0, mm - r] ] ],
{r, Min[mm, nn]}];
Union@ Flatten@ Table[
w = Apply[Join, Permutations /@ IntegerPartitions[n, Min[mm, n - 1] ] ];
Reap[Do[
Sow[Table[FromDigits[Flatten@
MapIndexed[ConstantArray[m[[First[#2] ]], #1] &,
w[[i]]], b], {m, s[[Length[w[[i]] ]]} ] ],
{i, Length[w]}] ][[-1, 1]], {n, 2, nn}]
CROSSREFS
KEYWORD
nonn,base,easy
AUTHOR
Michael De Vlieger, Nov 14 2024
STATUS
approved