This is a little codegolf challenge from codingame.com. I was wondering how much Python3 code is necessary (but of course answers are not limited to Python3).
The first line contains one positive integer n. The second line contains n positive integers. Each consecutive integers on the second line are separated by one space. There is no newline at the end of the second line.
One line containing the sum of the squares of the numbers on the second input line, and no white space except an optional newline at the end.
Each entry must be a complete program with input and output, not only a function. Shortest code wins.
For example, input:
5 1 2 5 7 8