Submission #429692

# Submission time Handle Problem Language Result Execution time Memory
429692 2021-06-16T08:45:59 Z mosiashvililuka The Collection Game (BOI21_swaps) C++14
5 / 100
96 ms 284 KB
#include "swaps.h"
#include<bits/stdc++.h>
using namespace std;
int a,b,c,d,e,i,j,ii,jj,zx,xc,V,bo[5009];
vector <int> vv,ans;
void solve(int N, int VV) {
	a=N;V=VV;
	for(ii=1; ii<a; ii++){
		c=a;while(bo[c]!=0) c--;
		for(i=a; i>=1; i--){
			if(bo[i]==1||i==c) continue;
			schedule(i,c);
			vv=visit();
			if(vv[0]==1){
				c=i;
			}
		}
		ans.push_back(c);
		bo[c]=1;
	}
	for(i=1; i<=a; i++){
		if(bo[i]==0){
			ans.push_back(i);break;
		}
	}
	answer(ans);
}
# Verdict Execution time Memory Grader output
1 Correct 1 ms 284 KB Correct
2 Correct 59 ms 200 KB Correct
3 Runtime error 51 ms 276 KB Execution killed with signal 11
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 200 KB Correct
2 Correct 66 ms 200 KB Correct
3 Runtime error 71 ms 284 KB Execution killed with signal 11
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 2 ms 200 KB Correct
2 Correct 75 ms 200 KB Correct
# Verdict Execution time Memory Grader output
1 Correct 2 ms 200 KB Correct
2 Correct 75 ms 200 KB Correct
3 Correct 1 ms 200 KB Correct
4 Correct 63 ms 200 KB Correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 200 KB Correct
2 Correct 66 ms 200 KB Correct
3 Runtime error 43 ms 200 KB Execution killed with signal 13
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 200 KB Correct
2 Correct 66 ms 200 KB Correct
3 Runtime error 43 ms 200 KB Execution killed with signal 13
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 200 KB Correct
2 Correct 56 ms 200 KB Correct
3 Runtime error 46 ms 200 KB Execution killed with signal 13
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 200 KB Correct
2 Correct 56 ms 200 KB Correct
3 Runtime error 46 ms 200 KB Execution killed with signal 13
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 2 ms 200 KB Correct
2 Correct 45 ms 200 KB Correct
3 Runtime error 96 ms 200 KB Execution killed with signal 13
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 2 ms 200 KB Correct
2 Correct 45 ms 200 KB Correct
3 Runtime error 96 ms 200 KB Execution killed with signal 13
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 200 KB Correct
2 Correct 41 ms 200 KB Correct
3 Runtime error 61 ms 200 KB Execution killed with signal 13
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 200 KB Correct
2 Correct 41 ms 200 KB Correct
3 Runtime error 61 ms 200 KB Execution killed with signal 13
4 Halted 0 ms 0 KB -