#include <bits/stdc++.h>
using namespace std;
int main() {
  string input;
  while (cin >> input) {
    if ((int)input.length() % 2 != 0) {
      cout << "NA" << endl;
      continue;
    }
    bool NAFlag = false;
    string output;
    while (input.length() > 0) {
      switch (input[0]) {
        case '1':
          output += 'a' + (input[1] - '0') - 1;
          break;
        case '2':
          output += 'f' + (input[1] - '0') - 1;
          break;
        case '3':
          output += 'k' + (input[1] - '0') - 1;
          break;
        case '4':
          output += 'p' + (input[1] - '0') - 1;
          break;
        case '5':
          output += 'u' + (input[1] - '0') - 1;
          break;
        case '6':
          switch (input[1]) {
            case '1':
              output += 'z';
              break;
            case '2':
              output += '.';
              break;
            case '3':
              output += '?';
              break;
            case '4':
              output += '!';
              break;
            case '5':
              output += ' ';
              break;
            default:
              NAFlag = true;
              break;
          }
          break;
        default:
          NAFlag = true;
          break;
      }
      if (NAFlag) {
        cout << "NA" << endl;
        continue;
      }
      input.erase(0, 2);
    }
    cout << output << endl;
  }
}
