Submission #110223

#TimeUTC-0UsernameProblemLanguageResultExecution timeMemory
1102232019-05-10 08:43:23SamAndBali Sculptures (APIO15_sculpture)C++17
25 / 100
1086 ms14612 KiB
#include <bits/stdc++.h>
using namespace std;
const int N = 2003, M = 102;
int n;
int ll, rr;
int a[N];
void solv0()
{
long long ans = (1LL << 62);
for (int x = 0; x < (1 << n); ++x)
{
if ((x & (1 << 0)) == 0)
continue;
vector<long long> v;
long long y = a[1];
for (int i = 1; i < n; ++i)
{
if ((x & (1 << i)))
{
v.push_back(y);
y = a[i + 1];
}
else
y += a[i + 1];
}
v.push_back(y);
long long yans = 0;
for (int i = 0; i < v.size(); ++i)
 
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Compilation message (stderr)

sculpture.cpp: In function 'void solv0()':
sculpture.cpp:30:27: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
         for (int i = 0; i < v.size(); ++i)
                         ~~^~~~~~~~~~
sculpture.cpp:32:16: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
         if (ll <= v.size() && v.size() <= rr)
             ~~~^~~~~~~~~~~
sculpture.cpp:32:40: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
         if (ll <= v.size() && v.size() <= rr)
                               ~~~~~~~~~^~~~~
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...