# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
134321 | 2019-07-22T12:27:20 Z | reda | Detecting Molecules (IOI16_molecules) | C++14 | 2 ms | 256 KB |
#include<bits/stdc++.h> using namespace std ; #define pb push_back #define ll long long #define ld long double #define mp make_pair #define MOD 1000000007 #define endl '\n' #pragma GCC optimize ("O3") #define fi first #define se second vector<int> ans; vector<int> find_subset(int l, int u, vector<int> w) { vector<pair<int,int>> v; for(int i=0;i<w.size();i++) v.pb(mp(w[i],i)); sort(v.begin(),v.end()); if(v[w.size()-1].fi<l || v[0].fi>u)return ans; ll sum =0; for(int i=0;i<w.size();i++) { sum+= v[i].fi; if(sum>u)break; if(sum>=l && sum<=u ) ans.pb(i); } return ans; } /*int main () { return 0 ; } */
Compilation message
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 2 ms | 256 KB | OK (n = 1, answer = NO) |
2 | Correct | 2 ms | 256 KB | OK (n = 1, answer = NO) |
3 | Correct | 2 ms | 256 KB | OK (n = 1, answer = YES) |
4 | Incorrect | 2 ms | 256 KB | Contestant can not find answer, jury can |
5 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Incorrect | 2 ms | 256 KB | Contestant can not find answer, jury can |
2 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 2 ms | 256 KB | OK (n = 1, answer = NO) |
2 | Correct | 2 ms | 256 KB | OK (n = 1, answer = NO) |
3 | Correct | 2 ms | 256 KB | OK (n = 1, answer = YES) |
4 | Incorrect | 2 ms | 256 KB | Contestant can not find answer, jury can |
5 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 2 ms | 256 KB | OK (n = 1, answer = NO) |
2 | Correct | 2 ms | 256 KB | OK (n = 1, answer = NO) |
3 | Correct | 2 ms | 256 KB | OK (n = 1, answer = YES) |
4 | Incorrect | 2 ms | 256 KB | Contestant can not find answer, jury can |
5 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 2 ms | 256 KB | OK (n = 1, answer = NO) |
2 | Correct | 2 ms | 256 KB | OK (n = 1, answer = NO) |
3 | Correct | 2 ms | 256 KB | OK (n = 1, answer = YES) |
4 | Incorrect | 2 ms | 256 KB | Contestant can not find answer, jury can |
5 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 2 ms | 256 KB | OK (n = 1, answer = NO) |
2 | Correct | 2 ms | 256 KB | OK (n = 1, answer = NO) |
3 | Correct | 2 ms | 256 KB | OK (n = 1, answer = YES) |
4 | Incorrect | 2 ms | 256 KB | Contestant can not find answer, jury can |
5 | Halted | 0 ms | 0 KB | - |