結果

問題 No.800 四平方定理
ユーザー hazohel
提出日時 2019-03-17 22:55:16
言語 PyPy3
(7.3.15)
結果
TLE  
実行時間 -
コード長 315 bytes
コンパイル時間 229 ms
コンパイル使用メモリ 82,188 KB
実行使用メモリ 90,424 KB
最終ジャッジ日時 2024-07-08 01:27:45
合計ジャッジ時間 6,546 ms
ジャッジサーバーID
(参考情報)
judge4 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample -- * 3
other TLE * 1 -- * 29
権限があれば一括ダウンロードができます

ソースコード

diff #

n = list(map(int, input().split()))
res = 0

for w in range(1, n[0]+ 1):
    for x in range(1, n[0] + 1):
        for y in range(1,n[0]+ 1):
            for z in range(1, n[0]+ 1):
                if(x**2 + y**2 + z**2 - w**2 ==  n[1]):
                    print(x, y, z, w)
                    res += 1
print(res)
0