#include <bits/stdc++.h>
#define ll long long
#define all(a) a.begin(),a.end()
#define mp make_pair
#define F first
#define S second
#define pii pair<int,int>
using namespace std;
vector<int> find_subset(int l , int r , vector<int> a){
int n = a.size() ;
vector<pii> w(n) ;
for(int i=0;i<n;i++){
w[i].F=a[i] ;
w[i].S =i ;
}
sort(all(w)) ;
//for(int i=1;i<n;i++) w[i].F+=w[i-1].F ;
int L = 0 , R= 0 ;
int sum = 0 ;
while(R!=n){
while(sum<l){
sum+=a[R] ;
R++ ;
}
while(sum>r){
sum-=a[L] ;
++L ;
}
if(sum>l){
vector<int> p ;
for(int i=L;i<R;i++) p.push_back(w[i].S) ;
return p ;
}
}
vector<int> poop ;
return poop ;
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Runtime error |
1 ms |
384 KB |
Execution killed with signal 11 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Execution timed out |
1094 ms |
256 KB |
Time limit exceeded |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Runtime error |
1 ms |
384 KB |
Execution killed with signal 11 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Runtime error |
1 ms |
384 KB |
Execution killed with signal 11 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Runtime error |
1 ms |
384 KB |
Execution killed with signal 11 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Runtime error |
1 ms |
384 KB |
Execution killed with signal 11 |
2 |
Halted |
0 ms |
0 KB |
- |