#include<iostream>
#include<stdio.h>
#include<string>
#include<vector>
using namespace std;
int main()
{
int n;
cin >> n;
string str;
for (int i = 0; i < n; i++)
{
for (int j = 0; j < 4; j++)
{
cin >> str;
if (str[2] == 'T')
{
switch (str[0])
{
case 'A':cout << "1"; break;
case 'B':cout << "2"; break;
case 'C':cout << "3"; break;
case 'D':cout << "4"; break;
default:
break;
}
}
}
}
system("pause");
return 0;
}
02-14
472
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
03-07
190
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
06-18
1163
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)