結果

問題 No.1176 少ない質問
ユーザー lemondolemondo
提出日時 2020-08-21 23:24:53
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 58 ms / 1,000 ms
コード長 421 bytes
コンパイル時間 131 ms
コンパイル使用メモリ 82,032 KB
実行使用メモリ 75,704 KB
最終ジャッジ日時 2024-04-23 06:33:47
合計ジャッジ時間 1,949 ms
ジャッジサーバーID
(参考情報)
judge2 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 51 ms
75,648 KB
testcase_01 AC 53 ms
73,984 KB
testcase_02 AC 58 ms
75,576 KB
testcase_03 AC 52 ms
75,704 KB
testcase_04 AC 55 ms
75,668 KB
testcase_05 AC 52 ms
75,248 KB
testcase_06 AC 52 ms
75,476 KB
testcase_07 AC 56 ms
75,388 KB
testcase_08 AC 55 ms
75,236 KB
testcase_09 AC 54 ms
75,484 KB
testcase_10 AC 55 ms
75,352 KB
testcase_11 AC 52 ms
73,656 KB
testcase_12 AC 54 ms
75,240 KB
testcase_13 AC 48 ms
73,476 KB
testcase_14 AC 52 ms
75,228 KB
testcase_15 AC 53 ms
75,660 KB
testcase_16 AC 56 ms
75,580 KB
testcase_17 AC 55 ms
75,220 KB
testcase_18 AC 50 ms
74,188 KB
testcase_19 AC 56 ms
75,224 KB
testcase_20 AC 38 ms
52,132 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
def input(): return sys.stdin.readline().strip()
def mapint(): return map(int, input().split())
sys.setrecursionlimit(10**9)

A = int(input())
ans = 10**10
for i in range(2, 1081):
    l, r = 0, 100
    if i>=A:
        ans = min(i, ans)
        break
    while l+1<r:
        half = -(-(l+r)//2)
        if i**half>=A:
            r = half
        else:
            l = half
    ans = min(ans, r*i)
print(ans)
0