login
Numbers whose base-8 representation has the same number of 0's and 5's.
0

%I #13 Sep 08 2022 08:44:53

%S 1,2,3,4,6,7,9,10,11,12,14,15,17,18,19,20,22,23,25,26,27,28,30,31,33,

%T 34,35,36,38,39,40,49,50,51,52,54,55,57,58,59,60,62,63,69,73,74,75,76,

%U 78,79,81,82,83,84,86,87,89,90,91,92,94,95,97,98,99,100,102,103,104

%N Numbers whose base-8 representation has the same number of 0's and 5's.

%t Select[Range[200], DigitCount[#, 8, 5] == DigitCount[#, 8, 0] &] (* _Vincenzo Librandi_, Oct 26 2016 *)

%o (Magma) [n: n in [1..120] | Multiplicity(S, 0) eq Multiplicity(S, 5) where S is {*d: d in Intseq(n, 8)*}]; // _Vincenzo Librandi_, Oct 26 2016

%K nonn,base,easy

%O 1,2

%A _Olivier GĂ©rard_