#include <bits/stdc++.h>
using namespace std;
int main() {
  string str;
  char poke[5][7] = {
      {"afkpuz"}, {"bglqv."}, {"chmrw?"}, {"dinsx!"}, {"ejoty "}};
  while (cin >> str) {
    if (str.size() % 2 != 0)
      cout << "NA" << endl;
    else {
      string ans;
      bool kawa = 0;
      for (int i = 1; i < str.size(); i += 2) {
        if (str[i - 1] - '1' < 0 || str[i - 1] - '1' > 5 || str[i] - '1' < 0 ||
            str[i] - '1' > 5) {
          kawa = 1;
          break;
        } else
          ans += poke[str[i] - '1'][str[i - 1] - '1'];
      }
      if (kawa)
        cout << "NA" << endl;
      else
        cout << ans << endl;
    }
  }
  return 0;
}
