# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
715094 | TheConverseEngineer | Bold (COCI21_bold) | C++17 | 1 ms | 308 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
using namespace std;
#define FOR(i, a, b) for(int i = a; i < (b); ++i)
#define all(x) begin(x), end(x)
#define sz(x) (int)(x).size()
#define sqr(x) ((ll)(x))*(x)
typedef long long ll;
typedef pair<int, int> pii;
typedef vector<int> vi;
char letter[102][102];
int N, M;
int main() {
cin >> N >> M;
FOR(y, 0, N) {
letter[0][y+1] = '.';
FOR(x, 0, M) {
cin >> letter[x+1][y+1];
}
}
FOR(x, 0, M) letter[x+1][0] = '.';
FOR(y, 0, N) {
FOR(x, 0, M) {
if (letter[x][y] == '#' or letter[x+1][y] == '#' or
letter[x][y+1] == '#' or letter[x+1][y+1] == '#') cout << "#";
else cout << ".";
}
cout << "\n";
}
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |