#include<bits/stdc++.h>
typedef long long int ll;
typedef unsigned long long int ull;
#define BIG_NUM 2000000000
#define HUGE_NUM 99999999999999999
#define MOD 1000000007
#define EPS 0.000000001
using namespace std;


#define NUM 55

int N;
vector<int> V;
bool check[NUM];

bool recursive(int);


bool dfs(int water_index,int current_index,int water_rest){
	if(water_rest == 0)return recursive(water_index+1);
	if(current_index == N)return false;

	if(check[current_index] == false && V[current_index] <= water_rest){
		check[current_index] = true;
		if(dfs(water_index,current_index+1,water_rest-V[current_index]))return true;
		check[current_index] = false;
	}
	return dfs(water_index,current_index+1,water_rest);
}

bool recursive(int index){

	if(index == N)return true;

	if(!check[index])return false;

	return dfs(index,index,V[index]) || recursive(index+1);
}

void func(){

	V.clear();

	int tmp;

	for(int loop = 0; loop < N; loop++){

		scanf("%d",&tmp);
		V.push_back(tmp);
	}

	if(N == 1){
		printf("YES\n");
		return;
	}

	sort(V.rbegin(),V.rend());

	check[0] = true;
	for(int i = 1; i < N; i++){

		check[i] = false;
	}

	if(recursive(0)){

		printf("YES\n");
	}else{

		printf("NO\n");
	}
}


int main(){

	while(true){

		scanf("%d",&N);
		if(N == 0)break;

		func();
	}

	return 0;
}

