Submission #740336

# Submission time Handle Problem Language Result Execution time Memory
740336 2023-05-12T10:57:10 Z nicky4321 The Collection Game (BOI21_swaps) C++14
21 / 100
54 ms 340 KB
//#pragma GCC optimize("Ofast,no-stack-protector")
//#pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,avx2,tune=native")
#include<bits/stdc++.h>
#include "swaps.h"
#define ll long long
#define ld long double
#define F first
#define S second
#define PB push_back
#define pii pair<int, int>
#define pll pair<ll, ll>
#define pdd pair<double, double>
#define ALL(x) x.begin(), x.end()
#define SZ(x) (int)x.size()
#define vi vector<int>
#define vl vector<ll>
#define CASE int t;cin>>t;for(int ca=1;ca<=t;ca++)
#define IOS ios_base::sync_with_stdio(false); cin.tie(0);
using namespace std;
const int MAX = 1 << 20, MOD = 1e9 + 7;

void solve(int N, int V) {
	vi v;
	ll n = N;
	if(n == 1){
		answer({1});
		return;
	}
	for(int i = 1;i <= n;i++) {
		v.push_back(i);
	}
	int cl = 1;
	for(int c = 0;c < n;c++){
		int l = cl;
		while(l + 1 <= n){
			schedule(l, l + 1);
			l += 2;
		}
		visit();
		if(cl == 2){
			cl = 1;
		}
		else{
			cl = 2;
		}
	}
	answer(v);
}
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 208 KB Not correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 208 KB Not correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 208 KB Correct
2 Correct 3 ms 208 KB Correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 208 KB Correct
2 Correct 3 ms 208 KB Correct
3 Incorrect 1 ms 208 KB Not correct
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 208 KB Correct
2 Correct 3 ms 208 KB Correct
3 Correct 10 ms 284 KB Correct
4 Correct 42 ms 300 KB Correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 208 KB Correct
2 Correct 3 ms 208 KB Correct
3 Correct 10 ms 284 KB Correct
4 Correct 42 ms 300 KB Correct
5 Incorrect 1 ms 208 KB Not correct
6 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 0 ms 208 KB Correct
2 Correct 3 ms 208 KB Correct
3 Correct 12 ms 208 KB Correct
4 Correct 37 ms 336 KB Correct
5 Correct 47 ms 304 KB Correct
# Verdict Execution time Memory Grader output
1 Correct 0 ms 208 KB Correct
2 Correct 3 ms 208 KB Correct
3 Correct 12 ms 208 KB Correct
4 Correct 37 ms 336 KB Correct
5 Correct 47 ms 304 KB Correct
6 Incorrect 1 ms 208 KB Not correct
7 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 208 KB Correct
2 Correct 3 ms 288 KB Correct
3 Correct 12 ms 208 KB Correct
4 Correct 54 ms 308 KB Correct
5 Correct 41 ms 340 KB Correct
6 Runtime error 8 ms 284 KB Execution killed with signal 13
7 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 208 KB Correct
2 Correct 3 ms 288 KB Correct
3 Correct 12 ms 208 KB Correct
4 Correct 54 ms 308 KB Correct
5 Correct 41 ms 340 KB Correct
6 Runtime error 8 ms 284 KB Execution killed with signal 13
7 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 208 KB Correct
2 Correct 2 ms 208 KB Correct
3 Correct 12 ms 208 KB Correct
4 Correct 43 ms 308 KB Correct
5 Correct 39 ms 288 KB Correct
6 Runtime error 13 ms 284 KB Execution killed with signal 13
7 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 208 KB Correct
2 Correct 2 ms 208 KB Correct
3 Correct 12 ms 208 KB Correct
4 Correct 43 ms 308 KB Correct
5 Correct 39 ms 288 KB Correct
6 Runtime error 13 ms 284 KB Execution killed with signal 13
7 Halted 0 ms 0 KB -