import java.util.*

fun main(args: Array<String>) {
  val sc = Scanner(System.`in`)
  val h = sc.nextInt()
  val w = sc.nextInt()
  val a = (1..h).map { sc.next() }

  val ans = mutableListOf<String>()
  val line = "#".repeat(w + 2)
  ans.add(line)
  for (ai in a) {
    val tmp = "#" + ai + "#"
    ans.add(tmp)
  }
  ans.add(line)

  println(ans.joinToString("\n"))

}
