object Main {
  val sc = new java.util.Scanner(System.in)

  def sin(n: Int): Seq[Int] = Seq.fill(n)(sc.nextInt())

  def main(args: Array[String]): Unit = {
    val n = sc.nextInt()
    sc.nextLine()
    val s = sc.nextLine()
    val k = sc.nextInt()

    println(
      s.foldLeft("")((b: String, c: Char) => b + (if (c == s(k - 1)) c else '*'))
    )
  }
}