# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
600527 | ChickTheNugget | Paint By Numbers (IOI16_paint) | C++17 | 1 ms | 212 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 ll long long
#define ld long double
#define INF 1e9
#define MOD 1e9 + 7
#define MAXN 1000
string solve_puzzle(string s, vector<int> c)
{
int n = s.size();
int k = c.size();
string ans = "";
if (c[0] > (n / 2)){
for (int i = 0; i < n - c[0]; i++){
ans += "?";
}
for (int i = 0; i < abs(n - 2 * c[0]); i++){
ans += "X";
}
for (int i = 0; i < n - c[0]; i++){
ans += "?";
}
}
else{
for (int i = 0; i < n; i++){
ans += "?";
}
}
return ans;
}
// int main()
// {
// ios_base::sync_with_stdio(0);
// cin.tie(0); cout.tie(0);
// #ifndef ONLINE_JUDGE
// freopen("input.txt", "r", stdin);
// freopen("output.txt", "w", stdout);
// #endif
// cout << solve_puzzle("........", {6});
// }
Compilation message (stderr)
# | 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... |