import Control.Monad

main = do
    [h, w] <- map read . words <$> getLine
    as <- replicateM h getLine :: IO [String]
    putStrLn $ concat $ replicate (w + 2) "#"
    mapM_ putStrLn $ map (\x -> "#" ++ x ++"#") as
    putStrLn $ concat $ replicate (w + 2) "#"