| # | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 | 
|---|---|---|---|---|---|---|---|
| 1262966 | silentloop | Detecting Molecules (IOI16_molecules) | C++20 | 385 ms | 67460 KiB | 
#include <bits/stdc++.h>
#define ll long long
#define sz(x) int(x.size())
#define fr first
#define se second
#define pb push_back
#define mp make_pair
#define all(x) x.begin(),x.end()
using namespace std;
std::vector<int> find_subset(int l, int u, std::vector<int> w) {
    vector<int>ans;
    if(l>u)
        return ans;
    vector<vector<int>>dp(u+1);
    vector<bool>pos(u+1);
    vector<pair<ll,ll>>v;
    ll i, j;
    for(i=0; i<sz(w); i++)
    {
        v.pb({w[i],i});
    }
    sort(all(v));
    pos[0]=1;
    for(i=0; i<sz(v); i++)
    {
        ll x=v[i].fr;
        int nod=v[i].se;
        for(j=u; j>=x; j--)
        {
            if(pos[j-x])
            {
                pos[j]=1;
                dp[j]=dp[j-x];
                dp[j].pb(nod);
                if(j>=l)
                    return dp[j];
            }
        }
    }
    return ans;
}
컴파일 시 표준 에러 (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... | ||||
