decode_table = [%w(a b c d e),
                %w(f g h i j),
                %w(k l m n o),
                %w(p q r s t),
                %w(u v w x y),
                ["z", ".", "?", "!", " "]]

loop do
  input_line = gets
  break if input_line.nil?
  
  if input_line.chomp.length.odd?
    puts "NA"
    next
  else
    mes = ""
    
    input_line.chomp.split("").each_slice(2) do |arr|
      mes += decode_table[arr[0].to_i - 1][arr[1].to_i - 1]
    end
    
    puts mes
  end
end