hottercolder.cpp:5:27: error: 'short int select [501][501][501]' redeclared as different kind of entity
5 | short select[501][501][501];
| ^
In file included from /usr/include/x86_64-linux-gnu/sys/types.h:179,
from /usr/include/stdlib.h:394,
from /usr/include/c++/10/cstdlib:75,
from /usr/include/c++/10/bits/stl_algo.h:59,
from /usr/include/c++/10/algorithm:62,
from hottercolder.cpp:1:
/usr/include/x86_64-linux-gnu/sys/select.h:101:12: note: previous declaration 'int select(int, fd_set*, fd_set*, fd_set*, timeval*)'
101 | extern int select (int __nfds, fd_set *__restrict __readfds,
| ^~~~~~
hottercolder.cpp: In function 'char dfs(int, int, int)':
hottercolder.cpp:15:18: warning: pointer to a function used in arithmetic [-Wpointer-arith]
15 | select[l][r][x] = i;
| ^
hottercolder.cpp:15:21: warning: pointer to a function used in arithmetic [-Wpointer-arith]
15 | select[l][r][x] = i;
| ^
hottercolder.cpp:15:24: warning: pointer to a function used in arithmetic [-Wpointer-arith]
15 | select[l][r][x] = i;
| ^
hottercolder.cpp:15:26: error: assignment of read-only location '*(select + ((((sizetype)l) + ((sizetype)r)) + ((sizetype)x)))'
15 | select[l][r][x] = i;
| ~~~~~~~~~~~~~~~~^~~
hottercolder.cpp:22:18: warning: pointer to a function used in arithmetic [-Wpointer-arith]
22 | select[l][r][x] = i;
| ^
hottercolder.cpp:22:21: warning: pointer to a function used in arithmetic [-Wpointer-arith]
22 | select[l][r][x] = i;
| ^
hottercolder.cpp:22:24: warning: pointer to a function used in arithmetic [-Wpointer-arith]
22 | select[l][r][x] = i;
| ^
hottercolder.cpp:22:26: error: assignment of read-only location '*(select + ((((sizetype)l) + ((sizetype)r)) + ((sizetype)x)))'
22 | select[l][r][x] = i;
| ~~~~~~~~~~~~~~~~^~~
hottercolder.cpp: In function 'int HC(int)':
hottercolder.cpp:39:29: warning: pointer to a function used in arithmetic [-Wpointer-arith]
39 | const int k = select[l][r][x];
| ^
hottercolder.cpp:39:32: warning: pointer to a function used in arithmetic [-Wpointer-arith]
39 | const int k = select[l][r][x];
| ^
hottercolder.cpp:39:35: warning: pointer to a function used in arithmetic [-Wpointer-arith]
39 | const int k = select[l][r][x];
| ^
hottercolder.cpp:39:35: error: invalid conversion from 'int (*)(int, fd_set*, fd_set*, fd_set*, timeval*)' to 'int' [-fpermissive]