import std.stdio;
import std.algorithm;
import std.string;
import std.functional;
import std.array;
import std.conv;
import std.math;
import std.typecons;
import std.regex;
import std.range;

real[12][1<<12] dp;
int[] cakes;
int n;

real saiki(int u,int v){
    if(dp[u][v] > 0) return dp[u][v];
    if( u == ((1<<n) - 1)) return cakes[v];

    real res = 10000000;
    for(int i=0;i<n;i++){
	if(( (1<<i) & u ) == 0){
	    res = min(res,saiki(u | (1<<i) ,i) + 2.0 * sqrt(to!real(cakes[i]*cakes[v]) )); 
	}
    }
    return dp[u][v] = res;
}

void main(){

    while(true){
	string s = readln();
	if(stdin.eof()) break;
	dp = new real[12][1<<12];
	auto s1 = s.split().to!(int[]);
	n = to!int(s1.length) - 1;
	cakes = (s1[1..$]).dup();
	cakes ~= 0;
	real ans = 1e8;
	for(int i=0;i<n;i++){
	    ans = min(saiki(1<<i,i) + cakes[i],ans);
	}
	writeln(ans <= s1[0] ? "OK" : "NA");

    }

}