結果
| 問題 | No.3108 Luke or Bishop |
| コンテスト | |
| ユーザー |
srjywrdnprkt
|
| 提出日時 | 2025-08-26 01:12:02 |
| 言語 | C++23 (gcc 15.2.0 + boost 1.90.0) |
| 結果 |
AC
|
| 実行時間 | 1 ms / 2,000 ms |
| + 361µs | |
| コード長 | 463 bytes |
| 記録 | |
| コンパイル時間 | 2,025 ms |
| コンパイル使用メモリ | 328,388 KB |
| 実行使用メモリ | 5,888 KB |
| 最終ジャッジ日時 | 2026-07-14 11:49:11 |
| 合計ジャッジ時間 | 3,636 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 26 |
ソースコード
#include <bits/stdc++.h>
//#include <atcoder/modint>
using namespace std;
//using namespace atcoder;
using ll = long long;
//using mint = modint998244353;
int main(){
cin.tie(nullptr);
ios_base::sync_with_stdio(false);
int gx, gy;
cin >> gx >> gy;
if (gx == 0 && gy == 0) cout << 0 << endl;
else if (abs(gx) == abs(gy)) cout << 1 << endl;
else if (gx == 0 || gy == 0) cout << 1 << endl;
else cout << 2 << endl;
return 0;
}
srjywrdnprkt