#include <iostream>

using namespace std;

int main() {
    int a, b, c;
    cin >> a >> b >> c;
    if (c <= a)cout << 0 << endl;
    else if (c <= a + b)cout << c - a << endl;
    else cout << "NA" << endl;
    return 0;
}
