結果
問題 | No.1934 Four Fruits |
ユーザー |
![]() |
提出日時 | 2022-05-13 21:33:35 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
RE
|
実行時間 | - |
コード長 | 693 bytes |
コンパイル時間 | 4,096 ms |
コンパイル使用メモリ | 258,508 KB |
最終ジャッジ日時 | 2025-01-29 06:39:22 |
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 6 RE * 1 |
ソースコード
#define _GLIBCXX_DEBUG #include <bits/stdc++.h> using namespace std; #define rep(i, n) for (int i = 0; i < (int)(n); i++) #define ALL(a) (a).begin(),(a).end() int main(){ vector<int> A(3); cin >> A[0] >> A[1] >> A[2]; sort(ALL(A)); if (A[0] == A[2]){ cout << A[0] << endl; } else { if ((A[0] == A[1]) || (A[1] == A[2])){ if (A[0] == A[1]){ cout << A[2] << endl; } else { cout << A[0] << endl; } } else { rep(i, 4){ if (A[i] != i){ cout << i << endl; return 0; } } } } }