Problem: 

Input

The first line of the input contains a single integer N (1 ≤ N ≤ 24). The next N lines contain 5 space-separated integers each. The first three integers will be between 0 and 2, inclusive. The last two integers will be between 0 and 3, inclusive. The sum of the first three integers will be equal to the sum of the last two integers.

Output

Output the result – a string of lowercase English letters.

Examples

Input


1
1 0 0 1 0


Output


a


Input


10
2 0 0 1 1
1 1 1 2 1
2 1 0 1 2
1 1 0 1 1
2 1 0 2 1
1 1 1 2 1
1 2 1 3 1
2 0 0 1 1
1 1 0 1 1
1 1 2 2 2


Output


codeforcez

Solution (in CPP):

Solution:
#include<stdio.h>
#include<algorithm>
#include<vector>
#include<queue>
#include<unordered_map>
#include<unordered_set>
#include<random>
#include<set>
#include<assert.h>
#include<string>
#include<time.h>
using namespace std;
using lld = long long int;
using ulld = unsigned long long int;
using pii = pair<int, int>;
using pli = pair<lld, int>;
using lf = double;
using pff = pair<lf, lf>;
int n, m;
int z[26][6] = {
	{1,0, 0,0, 0,0},
	{1,0, 1,0, 0,0},
	{1,1, 0,0, 0,0},
	{1,1, 0,1, 0,0},
	{1,0, 0,1, 0,0},

	{1,1, 1,0, 0,0},
	{1,1, 1,1, 0,0},
	{1,0, 1,1, 0,0},
	{0,1, 1,0, 0,0},
	{0,1, 1,1, 0,0},

	{1,0, 0,0, 1,0},
	{1,0, 1,0, 1,0},
	{1,1, 0,0, 1,0},
	{1,1, 0,1, 1,0},
	{1,0, 0,1, 1,0},

	{1,1, 1,0, 1,0},
	{1,1, 1,1, 1,0},
	{1,0, 1,1, 1,0},
	{0,1, 1,0, 1,0},
	{0,1, 1,1, 1,0},

	{1,0, 0,0, 1,1},
	{1,0, 1,0, 1,1},
	{0,1, 1,1, 0,1},
	{1,1, 0,0, 1,1},
	{1,1, 0,1, 1,1},

	{1,0, 0,1, 1,1},
};
int a[26][6];
void inil() {
	int i, j, k;
	for (i = 0; i < 26; i++) {
		a[i][0] = z[i][0] + z[i][1];
		a[i][1] = z[i][2] + z[i][3];
		a[i][2] = z[i][4] + z[i][5];
		a[i][3] = z[i][0] + z[i][2] + z[i][4];
		a[i][4] = z[i][1] + z[i][3] + z[i][5];
	}
}
int main() {
	inil();
	int t = 100, tv = 0;
	int i, j, k, l;
	scanf("%d", &t);
	while (t--) {
		int n;
		int b[5];
		for (i = 0; i < 5; i++) {
			scanf("%d", &b[i]);
		}
		for (k = 0; k < 26; k++) {
			for (j = 0; j < 5; j++) {
				if (a[k][j] != b[j])break;
			}
			if (j == 5) {
				printf("%c", k + 'a');
				break;
			}
		}
	}
	printf("\n");
}