login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A292456
Numbers where 6 outnumbers any other digit.
20
6, 66, 166, 266, 366, 466, 566, 606, 616, 626, 636, 646, 656, 660, 661, 662, 663, 664, 665, 666, 667, 668, 669, 676, 686, 696, 766, 866, 966, 1066, 1266, 1366, 1466, 1566, 1606, 1626, 1636, 1646, 1656, 1660, 1662, 1663, 1664, 1665, 1666
OFFSET
1,1
LINKS
EXAMPLE
606 has more 6's than any other digit, whereas 6006 has as many 0's as 6's.
MATHEMATICA
Select[Range[0, 1700], Max@ #1 < First@ #2 & @@ TakeDrop[RotateLeft[#, 6] &@ DigitCount@ #, 9] &] (* Michael De Vlieger, Sep 18 2017 *)
n6Q[n_]:=Module[{dc=DigitCount[n]}, dc[[6]]>Max[Drop[dc, {6}]]]; Select[ Range[ 2000], n6Q] (* Harvey P. Dale, Feb 19 2018 *)
PROG
(PARI) isok(n) = {d = digits(n); v = vector(10, n, #select(x->x==(n-1), d)); for (k=1, #v, if ((k != 7) && (v[k] >= v[7]), return(0)); ); return(1); } \\ Michel Marcus, Sep 21 2017
KEYWORD
nonn,base
AUTHOR
Halfdan Skjerning, Sep 18 2017
STATUS
approved