#include <bits/stdc++.h>
using namespace std;
char table[6][5] = {
    {'a', 'b', 'c', 'd', 'e'}, {'f', 'g', 'h', 'i', 'j'},
    {'k', 'l', 'm', 'n', 'o'}, {'p', 'q', 'r', 's', 't'},
    {'u', 'v', 'w', 'x', 'y'}, {'z', '.', '?', '!', ' '},
};
int main() {
  string s;
  while (cin >> s) {
    if (!(s.length() % 2)) {
      for (int i = 0; i < (int)s.length(); i += 2) {
        if (1 <= s[i] - '0' && s[i] - '0' <= 6 && 1 <= s[i + 1] - '0' &&
            s[i + 1] - '0' <= 5) {
          cout << table[s[i] - '0' - 1][s[i + 1] - '0' - 1];
        } else {
          cout << "NA";
          break;
        }
      }
    } else {
      cout << "NA";
    }
    cout << endl;
  }
  return 0;
}
