#include <bits/stdc++.h>
using namespace std;
int main(void) {
  string str;
  string hyo[] = {"abcde", "fghij", "klmno", "pqrst", "uvwxy", "z.?! "};
  while (cin >> str) {
    if (str.size() % 2) {
      cout << "NA" << endl;
      continue;
    }
    string out = "";
    for (int i = 0, len = str.size(); i < len; i += 2) {
      int x, y;
      y = str[i] - '1';
      x = str[i + 1] - '1';
      out += hyo[y][x];
    }
    cout << out << endl;
  }
  return 0;
}
