#K44507. Docking Port Identifiers
Docking Port Identifiers
Docking Port Identifiers
You are given a number of test cases T
. For each test case, you are provided with an integer n
representing the number of docking ports. Each docking port is assigned a unique identifier calculated as the square of its 1-indexed position.
Your task is to generate the list of identifiers for each docking port in every test case. For a given integer n
, output the identifiers as a sequence of space-separated numbers, where the i
th number is i^2
in LaTeX format, i.e., \(i^2\).
Example:
Input: 2 3 5</p>Output: 1 4 9 1 4 9 16 25
inputFormat
The input is read from standard input and is structured as follows:
- The first line contains an integer
T
representing the number of test cases. - The following
T
lines each contain a single integern
, wheren
denotes the number of docking ports.
outputFormat
For each test case, output a single line containing n
space-separated integers. Each integer is the square of its 1-indexed position (i.e., \(i^2\) for the i
th position).
1
3
1 4 9