Submission #32374959
Source Code Expand
#include "bits/stdc++.h"
using namespace std;
using ll = long long;
const int MOD = 1e9 + 7;
void printArr(vector<int>arr){
for(auto i : arr){
cout << i << " ";
}
cout << endl;
}
void printArrPair(vector<pair<int,int>>arr){
for(auto i : arr){
cout << i.first << " " << i.second << " ";
}
cout << endl;
}
int ans;
void dfs(vector<vector<int>>&g,int cur,bool sg,int f,int deph,int n){
if(g[cur].size() == 1){
ans = max(ans,n - deph * 2 + 2 - !sg);
}
if(sg){
ans = max(ans,n - deph - deph + 2);
}
for(int i : g[cur]){
if(i != f){
bool nsg = cur != 0 && g[cur].size() == 2;
dfs(g,i,nsg,cur,deph + 1,n);
}
}
}
void solve(){
int x,y;
cin >> x >> y;
x--;
y--;
vector<vector<int>>arr(2,vector<int>(2));
for(int i = 0;i < 2;i++){
for(int j = 0;j < 2;j++){
cin >> arr[i][j];
}
}
cout << arr[x][y] << endl;
}
int main(){
ios_base::sync_with_stdio(false);
cin.tie(NULL);
#ifndef ONLINE_JUDGE
freopen("data", "r", stdin);
#endif
int n = 1;
// cin >> n;
while(n--)
solve();
return 0;
}
Submission Info
| Submission Time | |
|---|---|
| Task | A - You should output ARC, though this is ABC. |
| User | liuji |
| Language | C++ (GCC 9.2.1) |
| Score | 100 |
| Code Size | 1203 Byte |
| Status | AC |
| Exec Time | 6 ms |
| Memory | 3632 KiB |
Judge Result
| Set Name | Sample | All | ||||
|---|---|---|---|---|---|---|
| Score / Max Score | 0 / 0 | 100 / 100 | ||||
| Status |
|
|
| Set Name | Test Cases |
|---|---|
| Sample | sample_01.txt, sample_02.txt, sample_03.txt |
| All | sample_01.txt, sample_02.txt, sample_03.txt, test_01.txt, test_02.txt, test_03.txt, test_04.txt, test_05.txt, test_06.txt, test_07.txt, test_08.txt, test_09.txt, test_10.txt, test_11.txt, test_12.txt |
| Case Name | Status | Exec Time | Memory |
|---|---|---|---|
| sample_01.txt | AC | 6 ms | 3600 KiB |
| sample_02.txt | AC | 3 ms | 3560 KiB |
| sample_03.txt | AC | 3 ms | 3520 KiB |
| test_01.txt | AC | 2 ms | 3600 KiB |
| test_02.txt | AC | 2 ms | 3600 KiB |
| test_03.txt | AC | 2 ms | 3572 KiB |
| test_04.txt | AC | 2 ms | 3492 KiB |
| test_05.txt | AC | 2 ms | 3632 KiB |
| test_06.txt | AC | 2 ms | 3600 KiB |
| test_07.txt | AC | 2 ms | 3628 KiB |
| test_08.txt | AC | 2 ms | 3560 KiB |
| test_09.txt | AC | 2 ms | 3572 KiB |
| test_10.txt | AC | 1 ms | 3628 KiB |
| test_11.txt | AC | 2 ms | 3632 KiB |
| test_12.txt | AC | 4 ms | 3524 KiB |