結果
| 問題 | No.1593 Perfect Distance |
| コンテスト | |
| ユーザー |
shiroha_F14
|
| 提出日時 | 2021-07-09 21:26:39 |
| 言語 | C++14 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 351 bytes |
| 記録 | |
| コンパイル時間 | 953 ms |
| コンパイル使用メモリ | 179,392 KB |
| 実行使用メモリ | 6,272 KB |
| 最終ジャッジ日時 | 2026-03-22 17:36:16 |
| 合計ジャッジ時間 | 1,572 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge1_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 8 WA * 9 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
#define fs(n) fixed << setprecision(n);
#define mp(a, b) make_pair(a, b);
using ll = long long;
using ld = long double;
int main(){
ll n; cin >> n;
int ans = 0;
for(ll i = 1; i < 500; i++){
for(ll j = 1; j < 500; j++){
if(n * n == i * i + j * j) ans++;
}
}
cout << ans << endl;
}
shiroha_F14