結果

問題 No.781 円周上の格子点の数え上げ
ユーザー MineMine
提出日時 2020-09-15 14:00:03
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 330 ms / 2,000 ms
コード長 207 bytes
コンパイル時間 307 ms
コンパイル使用メモリ 87,004 KB
実行使用メモリ 232,788 KB
最終ジャッジ日時 2023-09-04 01:41:17
合計ジャッジ時間 8,174 ms
ジャッジサーバーID
(参考情報)
judge15 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 285 ms
154,360 KB
testcase_01 AC 283 ms
154,604 KB
testcase_02 AC 281 ms
154,208 KB
testcase_03 AC 285 ms
154,368 KB
testcase_04 AC 288 ms
154,276 KB
testcase_05 AC 281 ms
154,360 KB
testcase_06 AC 281 ms
154,276 KB
testcase_07 AC 281 ms
154,212 KB
testcase_08 AC 284 ms
154,360 KB
testcase_09 AC 279 ms
154,364 KB
testcase_10 AC 294 ms
154,616 KB
testcase_11 AC 291 ms
154,672 KB
testcase_12 AC 308 ms
196,904 KB
testcase_13 AC 330 ms
232,788 KB
testcase_14 AC 281 ms
155,180 KB
testcase_15 AC 284 ms
154,360 KB
testcase_16 AC 282 ms
154,068 KB
testcase_17 AC 306 ms
200,780 KB
testcase_18 AC 283 ms
154,400 KB
testcase_19 AC 286 ms
154,360 KB
testcase_20 AC 283 ms
154,544 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

x, y = map(int, input().split())
num = [0]*(10**7+1)
for a in range(3164):
    for b in range(1, 3164):
        if a**2 + b**2 > 10**7:
            break
        num[a**2+b**2] += 1

print(max(num[x:y+1])*4)
0