#include <iostream>
#include <string>
#include <vector>
#include <sstream>
#include <cmath>
#include <climits>
using namespace std;
#define rep2(x,from,to) for(int x=(from);x<(to);++(x))
#define rep(x,to) rep2(x,0,to)

int main() {
	double dp[1<<12][12];
	double dist[16][32];
	rep(i,16) {
		rep2(j,i,32) {
			dist[i][j] = sqrt(j*j-i*i);
		}
	}
	int len, tmp;
	string s;
	while(getline(cin, s)) {
		stringstream ss(s);		
		vector<int> v;
		ss >> len;
		while(ss >> tmp) v.push_back(tmp);
		int n = v.size();
		rep(i,1<<12) {
			rep(j,12) {
				dp[i][j] = INT_MAX;
			}
		}
		rep(i,n) {
			dp[1<<i][i] = v[i];
		}
		rep(i,(1<<n)) {
			rep(j,n) {
				if(!(i&(1<<j))) continue;
				rep(k,n) {
					if(i&(1<<k)) continue;
					dp[i|1<<k][k] = min(dp[i|1<<k][k], dp[i][j]+dist[abs(v[k]-v[j])][v[k]+v[j]]);
				}
			}
		}
		bool f = 1;
		rep(i,n) {
			if(dp[(1<<n)-1][i] + v[i] <= len) {
				cout << "OK" << endl;
				f = 0;
				break;
			}
		}
		if(f) cout << "NA" << endl;
	}	
	return 0;
}