#include <iostream>
#include <fstream>
#include <vector>
#include <string>

using namespace std;

int main (){
	ifstream fin("DATA1.txt");
	ofstream fout("OUT1.txt");
	
	int i, a, b;
	
	for (i=0; i<5; ++i){
		fin >> a;
			if (a==1){
				fout << "#" << endl;
			}
			else if (a==3){
				fout << ".#." << endl << "###" << endl << ".#." << endl;
			}
			else if (a==5){
				fout << "..#.." << endl << ".###." << endl << "######" << endl << ".###." << endl << "..#.." << endl;
			}
			else if (a==7){
				fout << "...#..." << endl << "..###.." << endl << ".#####." << endl << "#######" << endl << ".#####." << endl << "..###.." << endl << "...#..." << endl;
			}
	}
	
	fout.close();
	fin.close();
	return 0;
}

