"use strict"
const Main = (input) =>{
  	let xs = input.trim().split("\n");
    let xs1 = xs[0].split(" ").map(Number);
    let H = xs1[0];
    let W = xs1[1];
    console.log(Array(W+3).join("#"));
    for(let i = 1; i<=H; i++){
    console.log("#%s#",xs[i]);//("#"+xs[i]+"#");
    }
    console.log(Array(W+3).join("#"));
}
Main(require("fs").readFileSync("/dev/stdin","utf8"));
