Sheep _ multiline split plane, sheep multiline split
We have seen many questions about straight line split planes. Today's questions are slightly changed. What we need is the maximum number of n line split planes. For example, a line can divide a plane into two parts. A line can divide a plane into seven parts at most, as shown below.
Input
The first line of the input data is an integer C, indicating the number of test instances, followed by data in Row C. Each row contains an integer n (0 <n <= 10000 ), the number of broken lines.
Output
For each test instance, specify the maximum number of partitions in the output plane. The output of each instance occupies one row.
The source code is as follows:
# Include <stdio. h>
Void main ()
{
Int n,;
Long x;
Scanf ("% d", & n );
While (n --)
{
Scanf ("% d", & );
X = 2 * a-a + 1;
Printf ("% lld \ n", x );
}
}