#include #define ll long long int #define INF 1000000000000000000 using namespace std; int main(void){ ll n; cin >> n; vector e(n); for (int i = 0; i < n; i++){ cin >> e[i]; } bool ok = 0; vector tri(n, 0); auto dfs = [&](auto &dfs, int k){ if (k == n){ vector a(3, 0); for (ll i = 0; i < n; i++){ a[tri[i]] += e[i]; } if (a[0] == a[1] && a[1] == a[2]) ok = 1; return; } tri[k] = 0; dfs(dfs, k+1); tri[k] = 1; dfs(dfs, k+1); tri[k] = 2; dfs(dfs, k+1); }; dfs(dfs, 0); if (ok) cout << "Yes" << endl; else cout << "No" << endl; return 0; }