import java.util.Scanner

object Main {
  def solve(sc: => Scanner): Unit = {
    var N = sc.nextInt
    while (N != 0) {
      if (N != 0) {
        var z = false
        for (_ <- 0 until N) {
          if (sc.nextInt == 0) (z = true)
        }
        println(if (z) ("NA") else (N + 1))
      }
      N = sc.nextInt
    }
  }


  def main(args: Array[String]): Unit = {
    val sc: Scanner = new Scanner(System.in)

    solve(sc)
  }
}