elephants.cpp: In function 'int update(int, int)':
elephants.cpp:82:25: error: incompatible types in assignment of 'int' to 'int [2000]'
s = getBuc(y);
^
elephants.cpp:83:14: error: invalid types 'int [2000][4001][int [2000]]' for array subscript
if (buc[s][0] == (t << 1)) getX(), reset(), s = getBuc(y);
^
elephants.cpp:83:61: error: incompatible types in assignment of 'int' to 'int [2000]'
if (buc[s][0] == (t << 1)) getX(), reset(), s = getBuc(y);
^
elephants.cpp:84:5: error: 'si' was not declared in this scope
si = lower_bound(buc[s] + 1, buc[s] + (buc[s][0] + 1), y) - buc[s];
^~
elephants.cpp:84:5: note: suggested alternative: 's'
si = lower_bound(buc[s] + 1, buc[s] + (buc[s][0] + 1), y) - buc[s];
^~
s
elephants.cpp:84:27: error: invalid types 'int [2000][4001][int [2000]]' for array subscript
si = lower_bound(buc[s] + 1, buc[s] + (buc[s][0] + 1), y) - buc[s];
^
elephants.cpp:84:39: error: invalid types 'int [2000][4001][int [2000]]' for array subscript
si = lower_bound(buc[s] + 1, buc[s] + (buc[s][0] + 1), y) - buc[s];
^
elephants.cpp:84:49: error: invalid types 'int [2000][4001][int [2000]]' for array subscript
si = lower_bound(buc[s] + 1, buc[s] + (buc[s][0] + 1), y) - buc[s];
^
elephants.cpp:84:70: error: invalid types 'int [2000][4001][int [2000]]' for array subscript
si = lower_bound(buc[s] + 1, buc[s] + (buc[s][0] + 1), y) - buc[s];
^
elephants.cpp:85:25: error: invalid types 'int [2000][4001][int [2000]]' for array subscript
for (int i = ++buc[s][0]; i > si; --i) {
^
elephants.cpp:86:14: error: invalid types 'int [2000][4001][int [2000]]' for array subscript
buc[s][i] = buc[s][i - 1];
^
elephants.cpp:86:26: error: invalid types 'int [2000][4001][int [2000]]' for array subscript
buc[s][i] = buc[s][i - 1];
^
elephants.cpp:88:10: error: invalid types 'int [2000][4001][int [2000]]' for array subscript
buc[s][si] = y;
^
elephants.cpp:90:13: error: invalid conversion from 'int*' to 'int' [-fpermissive]
recalc(s);
^
elephants.cpp:25:6: note: initializing argument 1 of 'void recalc(int)'
void recalc(int s) {
^~~~~~