1 solutions

  • 1
    @ 2024-4-4 17:16:13

    #include

    #include

    #include

    #include

    #include

    #include

    #include

    using namespace std;

    int main(){

    int h,w;

    char c,s;

    cin>>h>>w>>c>>s;

    for(int i=1;i<=h;i++){

    for(int j=1;j<=w;j++){

    if(s=='0'){

    if(i>1 && i<h && j>1 && j<w){

    cout<<" ";

    }

    else{

    cout<<c;

    }

    }

    else{

    cout<<c;

    }

    }

    printf("\n");

    }

    return 0;

    }

    • 1

    Information

    ID
    6898
    Time
    1000ms
    Memory
    512MiB
    Difficulty
    1
    Tags
    # Submissions
    7
    Accepted
    6
    Uploaded By