結果
| 問題 | No.2194 兄弟の掛け引き |
| コンテスト | |
| ユーザー |
kekenx
|
| 提出日時 | 2024-01-09 14:31:00 |
| 言語 | C++17 (gcc 15.2.0 + boost 1.90.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 376 bytes |
| 記録 | |
| コンパイル時間 | 539 ms |
| コンパイル使用メモリ | 78,976 KB |
| 実行使用メモリ | 9,972 KB |
| 最終ジャッジ日時 | 2026-07-03 09:06:49 |
| 合計ジャッジ時間 | 1,505 ms |
|
ジャッジサーバーID (参考情報) |
judge1_1 / judge3_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 12 WA * 2 |
ソースコード
#include <iostream>
#include <cassert>
using namespace std;
int main() {
ios::sync_with_stdio(false);
cin.tie(nullptr);
long long A, B, C; cin >> A >> B >> C;
bool ok = false;
if (C % A == 0) {
cout << C / A << endl;
ok = true;
}
if ((B + C) % A == 0) {
cout << (B + C) / A << endl;
ok = true;
}
if (!ok) cout << -1 << endl;
return 0;
}
kekenx