結果

問題 No.381 名声値を稼ごう Extra
ユーザー maspymaspy
提出日時 2020-03-17 13:16:48
言語 Python3
(3.11.6 + numpy 1.26.0 + scipy 1.11.3)
結果
RE  
(最新)
AC  
(最初)
実行時間 -
コード長 412 bytes
コンパイル時間 88 ms
コンパイル使用メモリ 10,792 KB
実行使用メモリ 9,700 KB
最終ジャッジ日時 2023-08-20 14:17:32
合計ジャッジ時間 609 ms
ジャッジサーバーID
(参考情報)
judge14 / judge12
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 15 ms
7,880 KB
testcase_01 RE -
権限があれば一括ダウンロードができます

ソースコード

diff #

#!/usr/bin/env python3.8
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines


def to_int(word):
    L = len(word)
    if len(word) < 10000:
        return int(word)
    mid = L // 2
    n1 = to_int(word[:mid])
    n2 = to_int(word[mid:])
    return pow(10, L - mid) * n1 + n2


N = to_int(read().rstrip())
answer = bin(N).count('1')
print(answer)
0