結果
問題 |
No.1113 二つの整数 / Two Integers
|
ユーザー |
![]() |
提出日時 | 2020-07-18 07:56:23 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 2 ms / 1,000 ms |
コード長 | 543 bytes |
コンパイル時間 | 1,690 ms |
コンパイル使用メモリ | 185,788 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-11-30 20:20:44 |
合計ジャッジ時間 | 2,584 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 15 |
ソースコード
#define _GLIBCXX_DEBUG #include <bits/stdc++.h> using namespace std; using ll = long long; #define rep(i, n) for (int i = 0; i < (int)(n); i++) #define all(v) v.begin(), v.end() #define inf 1e9 #define eps 1e-9 ll gcd(ll a, ll b) { if (b == 0) return a; return gcd(b, a % b); } int main() { ll a, b; cin >> a >> b; ll g = gcd(a, b); ll p1 = sqrt(g); double p2 = sqrt(g); if (p2 - p1 < eps) { cout << "Odd" << endl; } else { cout << "Even" << endl; } return 0; }