| # | Time | Username | Problem | Language | Result | Execution time | Memory | 
|---|---|---|---|---|---|---|---|
| 504073 | Newtech66 | Detecting Molecules (IOI16_molecules) | C++17 | 0 ms | 0 KiB | 
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include<bits/stdc++.h>
using namespace std;
int find_subset(int l,int u,int w[],int n,int result[])
{
    for(int i=0;i<n;i++)
    {
        if(l<=w[i] && w[i]<=u)
        {
            result[0]=i;
            return 1;
        }
    }
    for(int i=0;i<n;i++)
    {
        for(int j=i+1;j<n;j++)
        {
            if(l<=w[i]+w[j] && w[i]+w[j]<=u)
            {
                result[0]=i;
                result[1]=j;
                return 2;
            }
        }
    }
    return 0;
}
