| # | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
|---|---|---|---|---|---|---|---|
| 247092 | tqbfjotld | List of Unique Integers (FXCUP4_unique) | C++17 | 5 ms | 512 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include "unique.h"
#include <bits/stdc++.h>
using namespace std;
int arr1[205];
int arr2[205];
std::vector<int> PickUnique(int N) {
arr1[0] = 1;
arr2[N-1] = 1;
for (int x = 1; x<N; x++){
arr1[x] = UniqueCount(0,x);
}
for (int x = 0; x<N-1; x++){
arr2[x] = UniqueCount(x,N-1);
}
vector<int> ans;
if (arr2[0]>arr2[1]){
ans.push_back(1);
}
else{
ans.push_back(0);
}
for (int x = 1; x<N-1; x++){
if (arr2[x]>arr2[x+1] && arr1[x]>arr1[x-1]){
ans.push_back(1);
}
else{
ans.push_back(0);
}
}
if (arr1[N-1]>arr1[N-2]){
ans.push_back(1);
}
else{
ans.push_back(0);
}
return ans;
}
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
