#include <cstdlib>
#include <cstring>
#include <cmath>
#include <ctime>
#include <cassert>
#include <iostream>
#include <cctype>
#include <sstream>
#include <string>
#include <list>
#include <vector>
#include <queue>
#include <set>
#include <stack>
#include <map>
#include <utility>
#include <numeric>
#include <algorithm>
#include <iterator>
#include <bitset>
#include <complex>
#include <fstream>
using namespace std;
typedef long long ll;
const double EPS = 1e-9;
typedef vector<int> vint;
typedef pair<int, int> pint;
#define rep(i, n) REP(i, 0, n)
#define ALL(v) v.begin(), v.end()
#define MSG(a) cout << #a << " " << a << endl;
#define REP(i, x, n) for(int i = x; i < n; i++)
template<class T> T RoundOff(T a){ return int(a+.5-(a<0)); }
template<class T, class C> void chmax(T& a, C b){ if(a < b) a = b; }
template<class T, class C> void chmin(T& a, C b){ if(b < a) a = b; }
template<class T, class C> pair<T, C> mp(T a, C b){ return make_pair(a, b); }

vector<string> split(string str, string delim)
{
    vector<string> result;
    int cutAt;
    while( (cutAt = str.find_first_of(delim)) != str.npos )
    {
        if(cutAt > 0)
        {
            result.push_back(str.substr(0, cutAt));
        }
        str = str.substr(cutAt + 1);
    }
    if(str.length() > 0)
    {
        result.push_back(str);
    }
	return result;
}

int tonumber(string s)
{
	int res = 0;
	
	rep(i, s.size())
	{
		res *= 10;
		res += s[i] - '0';
	}
	
	return res;
}

bool rec(vint& R, int& n, int& H, double h, int prv, int S)
{	
	// end
	if(S == (1 << n) - 1)
	{
		return h + prv <= H;
	}
	
	bool res = false;
	
	rep(i, n)
	{
		if(!(S >> i & 1))
		{
			int dr = R[i] + prv;
			int dy = abs(R[i] - prv);
			double dx = sqrt(dr * dr - dy * dy);
			
			res |= rec(R, n, H, h + dx + (S == 0 ? R[i] : 0), R[i], S | 1 << i);
		}
	}
	
	return res;
}

int main()
{
	string line;
	while(getline(cin, line))
	{
		vector<string> ss = split(line,  " ");		
		
		int n = ss.size() - 1;
		int H = tonumber(ss[0]);
		
		vint R(n);
		
		rep(i, n)
			R[i] = tonumber(ss[i + 1]);
		
		
		cout << (rec(R, n, H, 0, 0, 0) ? "OK" : "NA") << endl;
	}
}