#include<iostream>
using namespace std;
  
int main(){
   int m, f, b;
   cin >> m >> f >> b;

   if (  b > (m + f) ) cout << "NA" << endl;
   else
   if ( b <= m ) cout << 0 << endl;
   else cout << b-m << endl;
return 0;
}
