MathCastle
Number TheorySuperchallengeDigits and Bases

Digits and Bases · Superchallenge problem

Let f(n)f(n) count the ones in the binary numeral of nn; for example f(13)=3f(13) = 3 because 13=1101213 = 1101_2. Compute ∑n=11000f(n)\displaystyle\sum_{n=1}^{1000} f(n).