# | 제출 시각UTC-0 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
661064 | mychecksedad | 메기 농장 (IOI22_fish) | C++17 | 431 ms | 123576 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <bits/stdc++.h>
using namespace std;
typedef long long int ll;
#define pb push_back
const int N = 1e5 + 100;
vector<ll> dp[N][2], pref[N][3], dp_pref[N], dp_suf[N], dp_pref_max[N]; //pref: 0 : itself, 1 : left one, 2 : right one
vector<int> v[N], p[N];
long long max_weights(int n, int m, std::vector<int> x, std::vector<int> y, std::vector<int> w){
for(int i = 0; i < m; ++i){
v[x[i]].pb(i);
if(x[i] > 0) v[x[i] - 1].pb(i);
if(x[i] < n - 1) v[x[i] + 1].pb(i);
}
for(int i = 0; i <= n; ++i){
int s = v[i].size() + 1;
p[i].pb(0);
for(int a: v[i]) p[i].pb(y[a] + 1);
sort(p[i].begin(), p[i].end());
for(int k = 0; k < 3; ++k){
pref[i][k].resize(s);
}
dp[i][0].resize(s);
dp[i][1].resize(s);
dp_pref[i].resize(s);
dp_suf[i].resize(s);
컴파일 시 표준 에러 (stderr) 메시지
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |