import io.StdIn.readLine


object Main {

  def main(args: Array[String]): Unit = {
    val str = readLine()
    val tf = for (i <- 0 to 15) yield (str.charAt(i) 1= "codefestival2016".charAt(i))
    println(tf.count(_))
  }

}
