Nathan Coulas

CCC '18 J1 - Telemarketer or not?

ccc18j1 CPP17 15 May, 2020 0.073s 3 points

Source Code

#include <bits/stdc++.h>
using namespace std;

typedef long long LL; 
typedef pair<int, int> pii; 
typedef pair<LL, LL> pll; 
typedef pair<string, string> pss; 
typedef vector<int> vi; 
typedef vector<vi> vvi; 
typedef vector<pii> vii; 
typedef vector<LL> vl; 
typedef vector<vl> vvl;
typedef queue<int> qi;
typedef queue<char> qc;
typedef stack<int> si;
typedef stack<char> sc;
#define F first
#define S second
#define PB push_back


int main(){
	ios::sync_with_stdio(0); cin.tie(0); cout.tie(0);

	//first is 8 or 9
	//last is 8 or 9
	//second and third are same
	string inp;
	string t;
	cin >> t;
	inp += t;
	cin >> t;
	inp += t;
	cin >> t;
	inp += t;
	cin >> t;
	inp += t;
	
	cout << (((inp[0] == '8' || inp[0] == '9') && (inp[3] == '8' || inp[3] == '9') && (inp[1] == inp[2])) ? "ignore" : "answer");
	
	return 0;
}