Task

Write a program to find the sum of squares of a numeric vector.

The program should work on a zero-length vector (with an answer of   0).



Related task

   Mean


$ cat toto
1
2
4
8
16
$ cat toto toto | paste -sd*
1*2*4*8*16*1*2*4*8*16
$ cat toto toto | paste -sd* | bc -l
1048576
 