結果
| 問題 |
No.1934 Four Fruits
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2022-07-02 11:28:50 |
| 言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 3 ms / 2,000 ms |
| コード長 | 426 bytes |
| コンパイル時間 | 2,187 ms |
| コンパイル使用メモリ | 193,804 KB |
| 最終ジャッジ日時 | 2025-01-30 03:52:11 |
|
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 7 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
using G=vector<vector<int>>;
typedef long long ll;
#define rep(i,l,r) for(int i=(l);i<(r);++i)
int main(){
vector<int> v(4);
rep(i,0,3){
int a; cin>>a;
v[a]++;
}
rep(i,0,4){
if(v[i]==3){cout<<i<<endl; return 0;}
}
rep(i,0,4){
if(v[i]==2){
rep(j,0,4){
if(v[j]==1){cout<<j<<endl; return 0;}
}
}
}
rep(i,0,4){
if(v[i]==0){cout<<i<<endl; return 0;}
}
}