結果
| 問題 |
No.800 四平方定理
|
| コンテスト | |
| ユーザー |
さいど
|
| 提出日時 | 2019-03-17 22:18:30 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 250 bytes |
| コンパイル時間 | 89 ms |
| コンパイル使用メモリ | 12,544 KB |
| 実行使用メモリ | 55,904 KB |
| 最終ジャッジ日時 | 2024-07-07 23:56:15 |
| 合計ジャッジ時間 | 3,902 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | -- * 3 |
| other | RE * 9 TLE * 1 -- * 20 |
ソースコード
import itertools import math N, D = [int(i) for i in input().split()] print(sum([1 if math.sqrt( i[0]**2+ i[1]**2 + i[2]**2 - D )%1 == 0 and math.sqrt( i[0]**2+ i[1]**2 + i[2]**2 - D ) <= N else 0 for i in itertools.product(range(1,N+1),repeat=3)]))
さいど