Submission #148807

# Submission time Handle Problem Language Result Execution time Memory
148807 2019-09-01T05:09:29 Z 맞WATLE(#3593, arnold518, ksmzzang2003, songc) King of Chairs (FXCUP4_chairs) C++17
100 / 100
159 ms 10456 KB
#include "king.h"

long long SendInfo(std::vector<int> W, std::vector<int> C){
	return 0;
}
#include <bits/stdc++.h>
#include "vassal.h"
using namespace std;
typedef long long LL;
typedef pair<int,int> pii;

int N;
set<pii> S;

void Init(long long B, std::vector<int> C){
	N = C.size();
	for (int i=0; i<N; i++) S.insert(pii(C[i], i));
}

int Maid(int W){
	auto it = S.lower_bound(pii(W, -1));
	if (it == S.end()) return -1;
	int ret = it->second;
	S.erase(it);
	return ret;
}
# Verdict Execution time Memory Grader output
1 Correct 11 ms 1052 KB Correct
2 Correct 11 ms 1056 KB Correct
3 Correct 11 ms 1060 KB Correct
4 Correct 10 ms 968 KB Correct
5 Correct 10 ms 796 KB Correct
# Verdict Execution time Memory Grader output
1 Correct 63 ms 5448 KB Correct
2 Correct 111 ms 9384 KB Correct
3 Correct 115 ms 10444 KB Correct
4 Correct 114 ms 10192 KB Correct
5 Correct 118 ms 10196 KB Correct
6 Correct 124 ms 10456 KB Correct
7 Correct 115 ms 10448 KB Correct
# Verdict Execution time Memory Grader output
1 Correct 79 ms 5960 KB Correct
2 Correct 136 ms 9636 KB Correct
3 Correct 141 ms 10444 KB Correct
4 Correct 153 ms 10452 KB Correct
5 Correct 159 ms 10456 KB Correct
6 Correct 151 ms 10368 KB Correct
7 Correct 131 ms 10452 KB Correct
8 Correct 129 ms 10184 KB Correct