题解 CF656D 【Rosetta Problem】

· · 题解

这种水题用python写最快了= = 一行搞定。 先转int再转八进制最后数 1 的个数

print(oct(int(input())).count('1'))