Borderou de evaluare (job #1223048)
Utilizator | Data | 25 august 2014 12:23:32 | |
---|---|---|---|
Problema | Heavy metal | Status | done |
Runda | Arhiva de probleme | Compilator | cpp | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.cpp:24:16: error: ‘int select [100003]’ redeclared as different kind of symbol
int select[NMAX], D[NMAX];
^
In file included from /usr/include/i386-linux-gnu/sys/types.h:220:0,
from /usr/include/stdlib.h:320,
from /usr/include/c++/4.8/cstdlib:72,
from /usr/include/c++/4.8/bits/stl_algo.h:59,
from /usr/include/c++/4.8/algorithm:62,
from user.cpp:2:
/usr/include/i386-linux-gnu/sys/select.h:107:12: error: previous declaration of ‘int select(int, fd_set*, fd_set*, fd_set*, timeval*)’
extern int select (int __nfds, fd_set *__restrict __readfds,
^
user.cpp: In function ‘int binarySearch(int, const int&)’:
user.cpp:30:23: warning: suggest parentheses around ‘+’ inside ‘>>’ [-Wparentheses]
middle = left + right >> 1;
^
user.cpp:31:28: warning: pointer to a function used in arithmetic [-Wpointer-arith]
if (V[select[middle]].right <= val)
^
user.cpp:31:29: error: invalid types ‘band [100003][int(int, fd_set*, fd_set*, fd_set*, timeval*)]’ for array subscript
if (V[select[middle]].right <= val)
^
user.cpp: In function ‘int main()’:
user.cpp:49:13: warning: pointer to a function used in arithmetic [-Wpointer-arith]
select[1] = 1;
^
user.cpp:49:15: error: assignment of read-only location ‘*(select + 1u)’
select[1] = 1;
^
user.cpp:49:15: error: cannot convert ‘int’ to ‘int(int, fd_set*, fd_set*, fd_set*, timeval*)’ in assignment
user.cpp:52:27: warning: pointer to a function used in arithmetic [-Wpointer-arith]
if (V[select[j - 1]].right <= V[i].left) {
^
user.cpp:52:27: warning: pointer to a function used in arithmetic [-Wpointer-arith]
user.cpp:52:28: error: invalid types ‘band [100003][int(int, fd_set*, fd_set*, fd_set*, timeval*)]’ for array subscript
if (V[select[j - 1]].right <= V[i].left) {
^
user.cpp:53:21: warning: pointer to a function used in arithmetic [-Wpointer-arith]
select[j] = i;
^
user.cpp:53:23: error: assignment of read-only location ‘*(select + ((sizetype)j))’
select[j] = i;
^
user.cpp:53:23: error: cannot convert ‘int’ to ‘int(int, fd_set*, fd_set*, fd_set*, timeval*)’ in assignment
user.cpp:61:25: warning: pointer to a function used in arithmetic [-Wpointer-arith]
select[j] = i;
^
user.cpp:61:27: error: assignment of read-only location ‘*(select + ((sizetype)j))’
select[j] = i;
^
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !