제출 #261264

#제출 시각UTC-0아이디문제언어결과실행 시간메모리
2612642020-08-11 15:37:12BertedProgression (NOI20_progression)C++14
100 / 100
1885 ms127056 KiB
#include <bits/stdc++.h>
#define ll long long
#define pii pair<ll, ll>
#define fst first
#define snd second
using namespace std;
const ll INF = 1e18;
const int SZ = (1 << 20) + 69;
inline pii getLine(pii p1, pii p2)
{
assert(p1.fst + 1 == p2.fst);
return {p2.snd - p1.snd, p1.snd * (1 + p1.fst) - p2.snd * p1.fst};
}
inline pii addLine(pii l1, pii l2) {return {l1.fst + l2.fst, l1.snd + l2.snd};}
inline pii getP(pii l, ll x) {return {x, l.fst * x + l.snd};}
struct node
{
pii lp = {INF, INF}, rp = {INF, INF}, lq = {INF, INF}, rq = {INF, INF};
int pl = 0, sl = 0, mxl = 0;
node() {}
};
node seg[SZ];
 
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

컴파일 시 표준 에러 (stderr) 메시지

Progression.cpp: In function 'void bld(int, int, int)':
Progression.cpp:121:13: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
   int M = L + R >> 1;
           ~~^~~
Progression.cpp: In function 'void upd(int, int, int, int, int, int, std::pair<long long int, long long int>)':
Progression.cpp:153:14: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
    int M = L + R >> 1;
            ~~^~~
Progression.cpp: In function 'node qry(int, int, int, int, int)':
Progression.cpp:169:24: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
    node ret; int M = L + R >> 1;
                      ~~^~~
#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...
#Verdict Execution timeMemoryGrader output
Fetching results...