#include<bits/stdc++.h>
using namespace std;
int main(){
    int a,b;
    bool mo ;
    char c;
    cin >> a >> b >> c >> mo;
    for(int i = 1;i <= a;i++){
    	if (mo == 0){
    	    for (int j = 1;j <= b;j++){
    		    if (i == 1 || i == a){
    		    	cout << c;
				}
				else{
					if (j== 1||j== b){
						cout << c;
					}
					else{
						cout <<' ';
					}
				}
		    }
		    cout << "\n";
		} 
		else{
			for (int j = 1;j <= b;j++){
				cout << c;
			}
		    cout << "\n";
		}
	} 
   return 0; 
}

0 条评论

目前还没有评论...