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>
#include "paint.h"
using namespace std;
string solve_puzzle(string s, vector<int> c) {
int le = s.size();
int mid = 2 * c[0] - le;
if ( mid < 0 ) mid = 0;
int bnd = ( le - mid ) / 2;
for ( int i = 0; i < bnd; i++ ) {
s[i] = '?';
}
for ( int i = bnd; i < bnd + mid; i++ ) {
s[i] = 'X';
}
for ( int i = bnd + mid; i < le; i++ ) {
s[i] = '?';
}
return s;
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |