object Main extends App {
  val in = scala.io.Source.stdin.getLines.toSeq
  val S = in.tail.head
  //val N = S.size
  val al = ('a' to 'z').map(_ => 0).toArray
  S.foreach(c => al(c - 'a') += 1)
  /*
  private def func(ex:Char):Long = {
	val excnt = S.count(_ != ex)
    //TODO mod
    Math.pow(2, excnt).toLong - 1
  }
  */
  val ret = (0 to ('z' - 'a')).foldLeft(1L){ (a,e) =>
    if(al(e) < 1) a else {
      a * (al(e) + 1) % 1000000007
    }
  }
  println(ret - 1)
}
