Sum of squares of digits
Execution time limit is 1 second
Runtime memory usage limit is 128 megabytes
Four-digit positive integer is given. Find the sum of squares of its digits.
Input
One four-digit positive integer n (1000 ≤ n ≤ 9999).
Output
Print the sum of squares of digits of number n.
Examples
Input #1
Answer #1
Submissions 10K
Acceptance rate 74%