結果

問題 No.1849 Three Times Value
ユーザー lloyzlloyz
提出日時 2022-03-11 21:10:40
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 87 ms / 2,000 ms
コード長 196 bytes
コンパイル時間 299 ms
コンパイル使用メモリ 87,244 KB
実行使用メモリ 76,164 KB
最終ジャッジ日時 2023-10-14 05:45:21
合計ジャッジ時間 4,562 ms
ジャッジサーバーID
(参考情報)
judge15 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 77 ms
71,244 KB
testcase_01 AC 77 ms
71,172 KB
testcase_02 AC 78 ms
71,208 KB
testcase_03 AC 77 ms
71,460 KB
testcase_04 AC 79 ms
71,240 KB
testcase_05 AC 78 ms
71,376 KB
testcase_06 AC 85 ms
75,908 KB
testcase_07 AC 75 ms
70,984 KB
testcase_08 AC 77 ms
71,168 KB
testcase_09 AC 85 ms
76,164 KB
testcase_10 AC 87 ms
75,668 KB
testcase_11 AC 85 ms
75,932 KB
testcase_12 AC 85 ms
75,920 KB
testcase_13 AC 82 ms
76,000 KB
testcase_14 AC 81 ms
75,812 KB
testcase_15 AC 78 ms
71,112 KB
testcase_16 AC 84 ms
76,036 KB
testcase_17 AC 82 ms
75,964 KB
testcase_18 AC 77 ms
71,336 KB
testcase_19 AC 76 ms
71,180 KB
testcase_20 AC 77 ms
71,316 KB
testcase_21 AC 75 ms
71,240 KB
testcase_22 AC 75 ms
71,268 KB
testcase_23 AC 74 ms
71,324 KB
testcase_24 AC 76 ms
71,352 KB
testcase_25 AC 77 ms
71,332 KB
testcase_26 AC 79 ms
76,124 KB
testcase_27 AC 81 ms
76,044 KB
testcase_28 AC 76 ms
71,244 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())

ans = 0
num = 1
power = 10
while num * power**2 + num * power + num <= n:
    ans += 1
    if len(str(num + 1)) - len(str(num)) == 1:
        power *= 10
    num += 1
print(ans)
0