n = int(input())
(*x,) = map(int, input().split())
a = round(sum(x) / n)
print(sum(((i - a) ** 2) for i in x)) n = int(input()) n int(input()) int input() input (*x,) = map(int, input().split()) *x x map(int, input().split()) map int input().split() ().split () input split a = round(sum(x) / n) a round(sum(x) / n) round sum(x) / n sum(x) sum x n print(sum(((i - a) ** 2) for i in x)) print sum(((i - a) ** 2) for i in x) sum (i - a) ** 2 i - a i a 2 n = int(input()) int(input()) n a = round(sum(x) / n) round(sum(x) / n) a
n = int(input())
(*x,) = map(int, input().split())
a = round(sum(x) / n)
print(sum(((i - a) ** 2) for i in x))