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 "prison.h"
#include <vector>
#include <bits/stdc++.h>
using namespace std;
vector<vector<int>>ans;
std::vector<std::vector<int>> devise_strategy(int N) {
ans.assign(N,vector<int>(N+1));
iota(ans[0].begin(),ans[0].end(),0);
ans[0][N]=N-1;
for(int i=1;i<N;i++){
ans[i][0]=1;
for(int j=1;j<=N;j++){
if(j<=i) ans[i][j]=-2;
else ans[i][j]=-1;
}
}
return ans;
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |