#C14460. Square Elements

    ID: 44112 Type: Default 1000ms 256MiB

Square Elements

Square Elements

Given a list of integers, your task is to compute the square of each element and output the squared values in the same order. Specifically, the input will begin with an integer n indicating the number of elements, followed by n integers separated by spaces. The output should be the squared values separated by a single space.

Note that if n is 0, the program should output nothing.

The relation for each element is given by:

$$ result_i = a_i^2, \quad 1 \leq i \leq n$$

inputFormat

The first line contains an integer n (0 ≤ n ≤ 10^5), representing the number of elements in the list. The second line contains n space-separated integers.

outputFormat

Output a single line containing n space-separated integers which are the squares of the given input numbers. If n is 0, output nothing.## sample

4
1 2 3 4
1 4 9 16