/* -*- coding: utf-8 -*- * * 2451.cc: No.2451 Redistribute Integers - yukicoder */ #include #include using namespace std; /* constant */ const int MAX_N = 500000; /* typedef */ typedef long long ll; /* global variables */ int as[MAX_N]; /* subroutines */ /* main */ int main() { int n; scanf("%d", &n); for (int i = 0; i < n; i++) scanf("%d", as + i); ll sum = 0; for (int i = 0; i < n; i++) sum += as[i]; if (sum % n == 0) puts("Yes"); else puts("No"); return 0; }