login
A039361
Numbers whose base-9 representation has the same nonzero number of 0's and 5's.
13
45, 86, 126, 167, 207, 248, 288, 329, 369, 406, 407, 408, 409, 411, 412, 413, 414, 423, 432, 441, 459, 468, 477, 491, 531, 572, 612, 653, 693, 743, 752, 761, 770, 775, 776, 777, 778, 780, 781, 782, 788, 797, 806, 815, 855, 896, 936, 977, 1017, 1058, 1098, 1135
OFFSET
1,1
LINKS
MATHEMATICA
Select[Range[1135], DigitCount[#, 9, 0]==DigitCount[#, 9, 5]>0&] (* Chris R. Rehmann, Apr 04 2026 *)
PROG
(MATLAB)
a = NaN(52, 1); k = 0; j = 1;
while any(isnan(a))
d = dec2base(k, 9)-'0';
n1 = sum(d==0); n2 = sum(d==5);
if n1==n2 && n1 > 0
a(j) = k; j = j+1;
end
k = k+1;
end
disp(regexprep(num2str(a'), ' +', ', ')) % Chris R. Rehmann, Apr 04 2026
KEYWORD
nonn,base,easy
STATUS
approved