object Main extends App {
  for (line <- scala.io.Source.stdin.getLines() if line.size >0 && line != "0 0") {
    for (h <- 1 to line.split(" ")(0).toInt) {
      val horizon: String = """???""" * line.split(" ")(1).toInt
      println(horizon)
    }
    println()
  }
}