結果
問題 |
No.1593 Perfect Distance
|
ユーザー |
![]() |
提出日時 | 2022-08-30 07:50:06 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
TLE
|
実行時間 | - |
コード長 | 338 bytes |
コンパイル時間 | 3,140 ms |
コンパイル使用メモリ | 215,856 KB |
最終ジャッジ日時 | 2025-02-06 23:51:48 |
ジャッジサーバーID (参考情報) |
judge3 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 12 TLE * 5 |
ソースコード
#pragma GCC target("avx2") #pragma GCC optimize("O3") #pragma GCC optimize("unroll-loops") #include <bits/stdc++.h> using namespace std; #define int long long signed main(){ int N; cin>>N; int ans = 0; for(int i=1;i<N;i++){ for(int j=1;i*i+j*j<=N*N;j++){ if(i*i+j*j == N*N) ans++; } } cout<<ans<<endl; }