# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
656189 | kinope | Bowling (BOI15_bow) | C++14 | 577 ms | 972 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;
typedef long long ll;
ll dp[302][11][11], dp2[302][11][11];
int p[11];
void Clear(){
for(int i = 0; i < 301; ++i)
for(int j = 0; j < 11; ++j)
for(int k = 0; k < 11; ++k) dp2[i][j][k]=0, dp[i][j][k]=0;
}
void Copy(){
for(int i = 0; i < 301; ++i)
for(int j = 0; j < 11; ++j)
for(int k = 0; k < 11; ++k) dp2[i][j][k]=dp[i][j][k], dp[i][j][k]=0;
}
void rozw(){
int n; string s=""; char c;
scanf("%d\n", &n);
for(int i = 0; i <= n<<1; ++i) c = getchar_unlocked(), s+=c;
//cin >> s;
for(int i = 1; i <= n; ++i) scanf("%d", &p[i]);
Clear();
for(int pkt = 301; ~pkt; --pkt) if(pkt==p[n]||p[n]==-1){
char t[3] = {s[n*2-2], s[n*2-1], s[n*2]};
//xxx
if(pkt-30>=0) if((t[0]=='x'||t[0]=='?') && (t[1]=='x'||t[1]=='?') && (t[2]=='x'||t[2]=='?')) ++dp[pkt-30][10][10];
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... |