Borderou de evaluare (job #2676220)

Utilizator mihail.ungureanuUngureanu Mihail mihail.ungureanu Data 23 noiembrie 2020 18:38:30
Problema Lowest Common Ancestor Status done
Runda Arhiva educationala Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp:10:34: warning: integer overflow in expression [-Woverflow] const int MAXN = 100000000000000 * 1000000000000000; ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~ main.cpp:17:21: error: size of array 'g' is not an integral constant-expression vector <int> g [MAXN]; ^ main.cpp:18:12: error: size of array 'h' is not an integral constant-expression int h [MAXN]; // Vertex height ^ main.cpp:20:16: error: size of array 'a_pos' is not an integral constant-expression int a_pos [MAXN]; // Positions in dfs list ^ main.cpp:22:36: error: size of array 'bt' is not an integral constant-expression int bt [MAXBLOCKS] [LOG_MAXLIST + 1]; // Sparse table on blocks (relative minimum positions in blocks) ^ main.cpp:23:21: error: size of array 'bhash' is not an integral constant-expression int bhash [MAXBLOCKS]; // Block hashes ^ main.cpp:25:19: error: overflow in constant expression int Log2 [2 * MAXN]; // Precalced logarithms (floored values) ^ main.cpp:25:19: error: size of array 'Log2' is too large main.cpp: In function 'void build_lca()': main.cpp:101:3: error: 'Log2' was not declared in this scope Log2 [i] = j; ^~~~ main.cpp: In function 'int lca(int, int)': main.cpp:121:13: error: 'Log2' was not declared in this scope int pw2 = Log2 [br-bl-1]; ^~~~ Non zero exit status: 1

Ceva nu functioneaza?