#define _USE_MATH_DEFINES
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <cmath>
#include <climits>
#include <cfloat>
#include <ctime>
#include <cassert>
#include <map>
#include <utility>
#include <set>
#include <iostream>
#include <memory>
#include <string>
#include <vector>
#include <algorithm>
#include <functional>
#include <sstream>
#include <complex>
#include <stack>
#include <queue>
#include <numeric>
#include <list>
#include <iomanip>
#include <iterator>
#include <cassert>

using namespace std;
typedef long long ll;
const int MODULO = 1000000007;
const int INF = 100000000; //1e8

typedef long long ll;
typedef pair<int,int> Pii;
typedef pair<ll,ll> Pll;
typedef complex<double> Cd;

#define FOR(i,n) for(int i = 0; i < (n); i++)
#define sz(c) ((int)(c).size())

template<class T>
void splitstr(const string &s, vector<T> &out)
{
    istringstream in(s);
    out.clear();
    copy(istream_iterator<T>(in), istream_iterator<T>(), back_inserter(out));
}

vector<int> a;
double memo[12][1 << 12];

double solve(int start,int flag,int rest){
	if(memo[start][flag] > 0) return memo[start][flag];
	if(rest == 0)
		return memo[start][flag] = a[start];
	double ret = INF;
	FOR(i,sz(a)){
		if((1<<i)&flag) continue;
		double add = solve(i,flag|(1<<i),rest - 1) + sqrt((double)a[start] * a[i]) * 2;
		ret = min(ret,add);
	}
	return memo[start][flag] = ret;
}

int main(){
	string s;
	while(getline(cin,s)){
		splitstr(s,a);
		int n = a[0];
		a.erase(a.begin());
		int m = sz(a);

		double mn = INF;
		FOR(j,m) fill(memo[j],memo[j] + (1 << m),-1.0);
		FOR(i,m){
			mn = min(mn,solve(i,1<<i,m-1) + a[i]);
		}

		cout << (n >= mn ? "OK" : "NA") << endl;
	}
	return 0;
}