CodeForces - 1339A

题目链接
**题目:**You have integer n. Calculate how many ways are there to fully cover belt-like area of 4n−2 triangles with diamond shapes.

Diamond shape consists of two triangles. You can move, rotate or flip the shape, but you cannot scale it.

2 coverings are different if some 2 triangles are covered by the same diamond shape in one of them and by different diamond shapes in the other one.

Please look at pictures below for better understanding.

On the left you can see the diamond shape you will use, and on the right you can see the area you want to fill.
These are the figures of the area you want to fill for n=1,2,3,4.

You have to answer t independent test cases.

Input
The first line contains a single integer t (1≤t≤104) — the number of test cases.

Each of the next t lines contains a single integer n (1≤n≤109).

Output
For each test case, print the number of ways to fully cover belt-like area of 4n−2 triangles using diamond shape. It can be shown that under given constraints this number of ways doesn’t exceed 1018.

Example
Input
2
2
1
Output
2
1
Note
In the first test case, there are the following 2 ways to fill the area:

In the second test case, there is a unique way to fill the area:
**题意:**你有整数n。计算有多少种方法可以完全覆盖4n−2个菱形三角形的带状区域。
菱形由两个三角形组成。您可以移动、旋转或翻转形状,但不能缩放它。两个覆盖物是不同的,如果有两个三角形被相同的菱形覆盖在其中一个,被不同的菱形覆盖在另一个
在左边你可以看到你将要使用的菱形,在右边你可以看到你想要填充的区域。
这些是n=1 2 3 4时,需要填充的面积。第一行包含单个整数t(1≤t≤104)-测试用例的数量。
接下来的t行每一行都包含一个整数n(1≤n≤109)。
对于每个测试用例,打印完全覆盖4n−2个菱形三角形带状区域的方法的数量。
**思路:**输入和输出一样就可以了。
代码:#include <stdio.h>
int main()
{
long long a,b;
scanf("%lld", &a);
while (a–)
{
scanf("%lld", &b);
printf("%lld\n",b);
}
return 0;
}
**总结:**英文水平得好。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值