#include using namespace std; bool ans[1005][1005]; int main() { int h, w, x; cin >> h >> w >> x; if(x < h + w - 2 || (x - (h + w - 2)) % 4){ cout << -1 << endl; return 0; } bool f = false; if(h % 4 == 3){ f = true; swap(h, w); } for(int i = 1; i < h / 4 * 4; i += 2){ if(i % 4 == 1){ for(int j = 0; j < w - 1; j++) ans[i][j] = true; } else{ for(int j = 1; j < w; j++) ans[i][j] = true; } } if(h % 4 == 3){ for(int j = 1; j < w; j += 2){ if(j % 4 == 1){ ans[h - 1][j] = ans[h - 2][j] = true; } else{ ans[h - 2][j] = ans[h - 3][j] = true; } } } int y = h * w - (h / 2) * (w - 1) - 1; if(h % 4 == 3){ y -= 2; for(int j = 3; j < w; j += 4){ if(y <= x) break; ans[h - 1][j] = true; ans[h - 3][j] = false; y -= 4; } } for(int i = 1; i < h; i += 4){ for(int j = w - 3; j >= 0; j -= 2){ if(y <= x) break; ans[i][j + 2] = true; ans[i][j] = false; y -= 4; } } if(y != x){ cout << -1 << endl; return 0; } if(f){ swap(h, w); for(int i = 0; i < max(h, w); i++){ for(int j = i + 1; j < max(h, w); j++) swap(ans[i][j], ans[j][i]); } } for(int i = 0; i < h; i++){ for(int j = 0; j < w; j++){ if(ans[i][j]) cout << '#'; else cout << '.'; } cout << endl; } }