| Task: | Classifier |
| Sender: | pwild |
| Submission time: | 2019-01-20 02:00:44 +0200 |
| Language: | C++ |
| Status: | READY |
| Result: | 43 |
| group | verdict | score |
|---|---|---|
| #1 | ACCEPTED | 19 |
| #2 | ACCEPTED | 24 |
| #3 | WRONG ANSWER | 0 |
| #4 | WRONG ANSWER | 0 |
| test | verdict | time | group | |
|---|---|---|---|---|
| #1 | ACCEPTED | 0.01 s | 1 | details |
| #2 | ACCEPTED | 0.02 s | 2 | details |
| #3 | WRONG ANSWER | 0.02 s | 3 | details |
| #4 | WRONG ANSWER | 0.02 s | 4 | details |
Code
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef vector<ll> vl;
typedef vector<vl> vvl;
typedef pair<ll,ll> pll;
typedef vector<bool> vb;
const ll oo = 0x3f3f3f3f3f3f3f3f;
const double eps = 1e-9;
#define sz(c) ll((c).size())
#define all(c) begin(c), end(c)
#define FOR(i,a,b) for (ll i = (a); i < (b); i++)
#define FORD(i,a,b) for (ll i = (b)-1; i >= (a); i--)
#define mp make_pair
#define mt make_tuple
#define pb push_back
#define eb emplace_back
#define xx first
#define yy second
#define has(c,i) ((c).find(i) != end(c))
#define TR(X) ({ if(1) cerr << "TR: " << (#X) << " = " << (X) << endl; })
vector<pair<string,string>> res2 = {
{"Z0","Z"},
{"Z1","Z"},
{"0Z","Z"},
{"1Z","Z"},
{"0M","M0"},
{"1M","M1"},
{"0N","N0"},
{"1N","N1"},
{"0BM","B"},
{"1BN","B"},
{"BM","Z"},
{"BN","Z"},
{"H0","0H"},
{"H1","1H"},
{"HE","C"},
{"D","BH"},
{"C00","00E"},
{"C01","01E"},
{"C10","10E"},
{"C11","11E"},
{"C0","Z"},
{"C1","Z"},
{"0C","MC"},
{"1C","NC"},
{"BC","_"},
{"B0","0D"},
{"B1","1D"},
{"1A","A1"},
{"A","BC"},
{"0","A0"},
{"11","_"}};
vector<pair<string,string>> res3 = {
{"Z0","Z"},
{"Z1","Z"},
{"0Z","Z"},
{"1Z","Z"},
{"0X","X0"},
{"1X","X1"},
{"0Y","Y0"},
{"1Y","Y1"},
{"0AX","A"},
{"1AY","A"},
{"AX","Z"},
{"AY","Z"},
{"0BX","XB"},
{"1BY","YB"},
{"BX","Z"},
{"BY","Z"},
{"Q0","0Q"},
{"Q1","1Q"},
{"QH","C"},
{"QG","BQ"},
{"F","AQ"},
{"C000","000H"},
{"C001","001H"},
{"C010","010H"},
{"C011","011H"},
{"C100","100H"},
{"C101","101H"},
{"C110","110H"},
{"C111","111H"},
{"C0","Z"},
{"C1","Z"},
{"0C","XC"},
{"1C","YC"},
{"B00","00G"},
{"B01","01G"},
{"B10","10G"},
{"B11","11G"},
{"ABC","_"},
{"A0","0F"},
{"A1","1F"},
{"1W","W1"},
{"W","ABC"},
{"0","W0"},
{"111","_"}};
int main() {
ios_base::sync_with_stdio(false);
cin.tie(NULL);
ll n; cin >> n;
vector<pair<string,string>> res;
if (n == 2) res = res2;
if (n == 3) res = res3;
cout << sz(res) << endl;
for (auto p: res) cout << p.xx << " -> " << p.yy << endl;
}
Test details
Test 1
Group: 1
Verdict: ACCEPTED
| input |
|---|
| 2 |
| correct output |
|---|
| 42 ED -> DE FD -> DF 1DG -> DG1 GE -> EG ... |
| user output |
|---|
| 31 Z0 -> Z Z1 -> Z 0Z -> Z 1Z -> Z ... Truncated |
Test 2
Group: 2
Verdict: ACCEPTED
| input |
|---|
| 3 |
| correct output |
|---|
| 54 ED -> DE FD -> DF HDG -> DGH IDG -> DGI ... |
| user output |
|---|
| 44 Z0 -> Z Z1 -> Z 0Z -> Z 1Z -> Z ... Truncated |
Test 3
Group: 3
Verdict: WRONG ANSWER
| input |
|---|
| 4 |
| correct output |
|---|
| 66 ED -> DE FD -> DF HDG -> DGH IDG -> DGI ... |
| user output |
|---|
| 0 |
Test 4
Group: 4
Verdict: WRONG ANSWER
| input |
|---|
| 5 |
| correct output |
|---|
| 78 ED -> DE FD -> DF HDG -> DGH IDG -> DGI ... |
| user output |
|---|
| 0 |
