提交时间:2023-11-10 09:43:32
运行 ID: 242
n = int(input()) count = 0 for i in range(1, n+1): count += str(i).count('1') print(count)