Submission #139217

# Submission time Handle Problem Language Result Execution time Memory
139217 2019-07-31T12:18:26 Z reda Detecting Molecules (IOI16_molecules) C++14
0 / 100
2 ms 376 KB
#include<bits/stdc++.h>
using namespace std ;
vector<int> find_subset(int l, int u,  vector<int> w)
 {
     vector<int>ans  ;
     for(int  i= 0 ;i < w.size();i++)
     {
         for(int  j = 0;j<w.size();j++)
         {
             if(i==j)continue;
             if(l<=w[i]+w[j] && w[i]+w[j]<=u)
             {ans.push_back(j);ans.push_back(i);break;}
         }
     }
     return ans;
 }

Compilation message

molecules.cpp: In function 'std::vector<int> find_subset(int, int, std::vector<int>)':
molecules.cpp:6:23: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
      for(int  i= 0 ;i < w.size();i++)
                     ~~^~~~~~~~~~
molecules.cpp:8:26: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
          for(int  j = 0;j<w.size();j++)
                         ~^~~~~~~~~
# Verdict Execution time Memory 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 Incorrect 2 ms 376 KB Contestant can not find answer, jury can
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 2 ms 256 KB Contestant can not find answer, jury can
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory 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 Incorrect 2 ms 376 KB Contestant can not find answer, jury can
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory 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 Incorrect 2 ms 376 KB Contestant can not find answer, jury can
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory 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 Incorrect 2 ms 376 KB Contestant can not find answer, jury can
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory 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 Incorrect 2 ms 376 KB Contestant can not find answer, jury can
4 Halted 0 ms 0 KB -