結果
| 問題 | No.1593 Perfect Distance |
| コンテスト | |
| ユーザー |
Fullmoon85072
|
| 提出日時 | 2021-11-28 14:53:54 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
TLE
|
| 実行時間 | - |
| コード長 | 276 bytes |
| 記録 | |
| コンパイル時間 | 1,447 ms |
| コンパイル使用メモリ | 85,372 KB |
| 実行使用メモリ | 144,956 KB |
| 最終ジャッジ日時 | 2026-03-22 06:33:20 |
| 合計ジャッジ時間 | 26,852 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 9 TLE * 8 |
ソースコード
import math
N = int(input())
twoN = math.pow(N, 2)
count = 0
for x in range(N):
for y in range(N):
dx = math.pow(x, 2)
dy = math.pow(y, 2)
if dx + dy == twoN:
count += 1
elif dx + dy > twoN:
continue
print(count)
Fullmoon85072