結果

問題 No.1593 Perfect Distance
ユーザー kuhaku
提出日時 2021-07-09 22:48:38
言語 C++17
(gcc 13.3.0 + boost 1.87.0)
結果
WA  
実行時間 -
コード長 262 bytes
コンパイル時間 2,268 ms
コンパイル使用メモリ 191,324 KB
最終ジャッジ日時 2025-01-22 22:24:41
ジャッジサーバーID
(参考情報)
judge2 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2 WA * 1
other AC * 5 WA * 12
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;

int main(void) {
    int n;
    cin>>n;
    int ans=0;
    for (int x=1; x < 2000; ++x) {
        for (int y = 1; y<2000;++y) {
            ans += x*x+y*y==n;
        }
    }
    cout << ans << endl;
    return 0;
}
0