Submission #733373

#TimeUTC-0UsernameProblemLanguageResultExecution timeMemory
7333732023-04-30 15:20:47benjaminkleynExamination (JOI19_examination)C++17
100 / 100
696 ms55300 KiB
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
struct Query
{
int A, B, C, idx;
int a, b;
Query() : a(0), b(0), A(0), B(0), C(0), idx(0) {}
Query(int _a, int _b, int _c, int _idx) : a(0), b(0), A(_a), B(_b), C(_c), idx(_idx) {}
};
struct Student
{
int S, T, idx;
int s, t;
Student() : s(0), t(0), S(0), T(0), idx(0) {}
};
int n, q;
struct SegTree
{
int t[1000000] = {0};
SegTree() {}
void update(int idx, int v = 1, int tl = 0, int tr = 200000)
{
if (tl == tr)
{
t[v]++;
 
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Compilation message (stderr)

examination.cpp: In constructor 'Query::Query()':
examination.cpp:8:12: warning: 'Query::b' will be initialized after [-Wreorder]
    8 |     int a, b;
      |            ^
examination.cpp:7:9: warning:   'int Query::A' [-Wreorder]
    7 |     int A, B, C, idx;
      |         ^
examination.cpp:9:5: warning:   when initialized here [-Wreorder]
    9 |     Query() : a(0), b(0), A(0), B(0), C(0), idx(0) {}
      |     ^~~~~
examination.cpp: In constructor 'Query::Query(int, int, int, int)':
examination.cpp:8:12: warning: 'Query::b' will be initialized after [-Wreorder]
    8 |     int a, b;
      |            ^
examination.cpp:7:9: warning:   'int Query::A' [-Wreorder]
    7 |     int A, B, C, idx;
      |         ^
examination.cpp:10:5: warning:   when initialized here [-Wreorder]
   10 |     Query(int _a, int _b, int _c, int _idx) : a(0), b(0), A(_a), B(_b), C(_c), idx(_idx) {}
      |     ^~~~~
examination.cpp: In constructor 'Student::Student()':
examination.cpp:16:12: warning: 'Student::t' will be initialized after [-Wreorder]
   16 |     int s, t;
      |            ^
examination.cpp:15:9: warning:   'int Student::S' [-Wreorder]
   15 |     int S, T, idx;
      |         ^
examination.cpp:17:5: warning:   when initialized here [-Wreorder]
   17 |     Student() : s(0), t(0), S(0), T(0), idx(0) {}
      |     ^~~~~~~
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...