結果
| 問題 | No.3180 angles sum |
| コンテスト | |
| ユーザー |
沙耶花
|
| 提出日時 | 2025-06-13 22:18:22 |
| 言語 | C++17 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
CE
(最新)
AC
(最初)
|
| 実行時間 | - |
| コード長 | 807 bytes |
| 記録 | |
| コンパイル時間 | 2,672 ms |
| コンパイル使用メモリ | 229,028 KB |
| 最終ジャッジ日時 | 2026-01-09 02:37:10 |
| 合計ジャッジ時間 | 5,520 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
コンパイルエラー時のメッセージ・ソースコードは、提出者また管理者しか表示できないようにしております。(リジャッジ後のコンパイルエラーは公開されます)
ただし、clay言語の場合は開発者のデバッグのため、公開されます。
ただし、clay言語の場合は開発者のデバッグのため、公開されます。
コンパイルメッセージ
次のファイルから読み込み: /usr/include/atcoder/modint.hpp:5,
次から読み込み: /usr/include/atcoder/modint:1,
次から読み込み: /usr/include/atcoder/convolution.hpp:11,
次から読み込み: /usr/include/atcoder/convolution:1,
次から読み込み: /usr/include/atcoder/all:1,
次から読み込み: main.cpp:2:
/usr/local/gcc-15/include/c++/15.2.0/numeric: In instantiation of ‘constexpr std::common_type_t<_Mn, _Nn> std::gcd(_Mn, _Nn) [with _Mn = __int128; _Nn = __int128; common_type_t<_Mn, _Nn> = __int128]’:
main.cpp:30:20: required from here
30 | __int128 g = gcd(a[i],b[i]);
| ~~~^~~~~~~~~~~
/usr/local/gcc-15/include/c++/15.2.0/numeric:181:21: エラー: static assertion failed: std::gcd arguments must be integers
181 | static_assert(is_integral_v<_Mn> && is_integral_v<_Nn>,
| ^~~~~~~~~~~~~~~~~~
/usr/local/gcc-15/include/c++/15.2.0/numeric:181:21: 備考: ‘std::is_integral_v<__int128>’ evaluates to false
次のファイルから読み込み: /usr/local/gcc-15/include/c++/15.2.0/bits/cpp_type_traits.h:42,
次から読み込み: /usr/local/gcc-15/include/c++/15.2.0/bits/stl_algobase.h:61,
次から読み込み: /usr/local/gcc-15/include/c++/15.2.0/algorithm:62,
次から読み込み: /usr/include/atcoder/convolution.hpp:4:
/usr/local/gcc-15/include/c++/15.2.0/type_traits: In instantiation of ‘struct std::make_unsigned<__int128>’:
/usr/local/gcc-15/include/c++/15.2.0/type_traits:2143:11: required by substitution of ‘template<class _Tp> using std::make_unsigned_t = typename std::make_unsigned::type [with _Tp = __int128]’
2143 | using make_unsigned_t = typename make_unsigned<_Tp>::type;
| ^~~~~~~~~~~~~~~
/usr/local/gcc-15/include/c++/15.2.0/numeric:188:24: required from ‘constexpr std::common_type_t<_Mn, _Nn> std::gcd(_M
ソースコード
#include <stdio.h>
#include <atcoder/all>
#include <bits/stdc++.h>
using namespace std;
using namespace atcoder;
using mint = modint998244353;
#define rep(i,n) for (int i = 0; i < (n); ++i)
#define Inf32 1000000005
#define Inf64 4000000000000000001LL
int main(){
int _t;
cin>>_t;
rep(_,_t){
vector<long long> x(3),y(3);
rep(i,3)cin>>x[i]>>y[i];
vector<long long> r(3);
rep(i,3){
r[i] = x[i] * x[i] + y[i] * y[i];
}
bool f = true;
vector<__int128> a(2),b(2);
a[0] = x[0]*x[1]- y[0]*y[1];
if(a[0] * x[2] < 0)f = false;
a[0] *= a[0];
a[1] = x[2] * x[2];
b[0] = r[0];
b[0] *= r[1];
b[1] = r[2];
rep(i,2){
__int128 g = gcd(a[i],b[i]);
a[i] /= g,b[i] /= g;
}
if(a[0]!=a[1] || b[0]!=b[1])f = false;
if(f)cout<<"Yes"<<endl;
else cout<<"No"<<endl;
}
return 0;
}
沙耶花