#include <iostream>
using namespace std;
int main() {
  int W;
  cin >> W >> W;
  auto a = [&]() { cout << string(W + 2, '#') << endl; };
  a();
  string S;
  while (cin >> S) {
    cout << '#' << S << "#\n";
  }
  a();
  return 0;
}
