A. Trippi Troppi

time limit per test

1 second

memory limit per test

256 megabytes

Trippi Troppi resides in a strange world. The ancient name of each country consists of three strings. The first letter of each string is concatenated to form the country's modern name.

Given the country's ancient name, please output the modern name.

Input

The first line contains an integer tt – the number of independent test cases (1≤t≤1001≤t≤100).

The following tt lines each contain three space-separated strings. Each string has a length of no more than 1010, and contains only lowercase Latin characters.

Output

For each test case, output the string formed by concatenating the first letter of each word.

Example

Input

Copy

 

7

united states america

oh my god

i cant lie

binary indexed tree

believe in yourself

skibidi slay sigma

god bless america

Output

Copy

usa
omg
icl
bit
biy
sss
gba

解题说明:水题,每个字符串取第一个字母即可。

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


int main() 
{
	int t;
	char a[12], b[12], c[12];
	cin >> t;
	while (t--) 
	{
		scanf("%s %s %s\n", &a, &b, &c);
		printf("%c%c%c\n", a[0], b[0], c[0]);
	}
	return 0;
}

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值