#include<iostream>
#include<cstring>
#include<algorithm>
#include<vector>
#include<map>

using namespace std;

int N;
int Volume[50];
bool WaterIn[50], Tmp[50];


bool calculation(int id, int volumeOfCurrent) {
	//cout << "rest:" << volumeOfCurrent << "      :id" << id << endl;

	if (id < -1) {
		return false;
	}
	if (volumeOfCurrent == 0) {
		return true;
	}
	
	if (!Tmp[id]) {
		return calculation(id - 1, volumeOfCurrent);
	}

	if (Volume[id] <= volumeOfCurrent) {
		Tmp[id] = false;
		if (calculation(id - 1, volumeOfCurrent - Volume[id])) {
			return true;
		}
		Tmp[id] = true;
	}
	
	return calculation(id - 1, volumeOfCurrent);
}

bool solve(int beakerId, int rest) {
	
	if (rest == 0) {
		//judge
		copy(WaterIn, WaterIn + N, Tmp);
		/*for (int i = 0; i < N; ++i) {
			Tmp[i] = WaterIn[i];
		}*/
		for (int i = 0; i < N; ++i) {
			if (Tmp[i]) {
				continue;
			}
			if (!calculation(i-1, Volume[i])) {
				return false;
			}
			Tmp[i] = true;
		}
		return true;
	}

	if (Volume[beakerId] > rest) {
		return false;
	}

	WaterIn[beakerId] = true;
	if (solve(beakerId + 1, rest - Volume[beakerId])) {
		return true;
	}
	WaterIn[beakerId] = false;
	return (solve(beakerId + 1, rest));
}

int main() {

	while (cin >> N, N) {
		memset(Volume, 0, sizeof(Volume));
		memset(WaterIn, false, sizeof(WaterIn));
		for (int i = 0; i < N; ++i) {
			cin >> Volume[i];
		}
		sort(Volume, Volume + N);
		WaterIn[0] = true;
	
		if (solve(1, Volume[N - 1] - Volume[0])) {
			cout << "YES" << endl;
		}
		else {
			cout << "NO" << endl;
		}
	}

	return 0;
}


