Borderou de evaluare (job #1458018)
Utilizator | Data | 5 iulie 2015 20:35:10 | |
---|---|---|---|
Problema | Algola | Status | done |
Runda | Arhiva de probleme | Compilator | cpp | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.cpp:13:63: error: ‘int time’ redeclared as different kind of symbol
int n, viz[MAX], dad[MAX], sum, x[MAX], y[MAX], c[MAX], flow, time;
^
In file included from /usr/include/pthread.h:26:0,
from /usr/include/i386-linux-gnu/c++/4.8/bits/gthr-default.h:35,
from /usr/include/i386-linux-gnu/c++/4.8/bits/gthr.h:148,
from /usr/include/c++/4.8/ext/atomicity.h:33,
from /usr/include/c++/4.8/bits/ios_base.h:39,
from /usr/include/c++/4.8/ios:42,
from /usr/include/c++/4.8/ostream:38,
from /usr/include/c++/4.8/iostream:39,
from user.cpp:1:
/usr/include/time.h:186:15: error: previous declaration of ‘time_t time(time_t*)’
extern time_t time (time_t *__timer) __THROW;
^
user.cpp: In function ‘int main()’:
user.cpp:71:14: error: assignment of function ‘time_t time(time_t*)’
for(time = 0 ; time <= 100 ; time++)
^
user.cpp:71:14: error: cannot convert ‘int’ to ‘time_t(time_t*)throw () {aka long int(long int*)throw ()}’ in assignment
user.cpp:71:28: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
for(time = 0 ; time <= 100 ; time++)
^
user.cpp:71:38: error: ISO C++ forbids incrementing a pointer of type ‘time_t (*)(time_t*)throw () {aka long int (*)(long int*)throw ()}’ [-fpermissive]
for(time = 0 ; time <= 100 ; time++)
^
user.cpp:71:38: error: lvalue required as increment operand
user.cpp:73:16: warning: the address of ‘time_t time(time_t*)’ will always evaluate as ‘true’ [-Waddress]
if(time)
^
user.cpp:77:42: warning: pointer to a function used in arithmetic [-Wpointer-arith]
make_edge(node(i, time - 1), node(i, time), 50);
^
user.cpp:77:40: error: invalid conversion from ‘time_t (*)(time_t*)throw () {aka long int (*)(long int*)throw ()}’ to ‘int’ [-fpermissive]
make_edge(node(i, time - 1), node(i, time), 50);
^
user.cpp:14:5: error: initializing argument 2 of ‘int node(int, int)’ [-fpermissive]
int node(int x, int y)
^
user.cpp:77:58: error: invalid conversion from ‘time_t (*)(time_t*)throw () {aka long int (*)(long int*)throw ()}’ to ‘int’ [-fpermissive]
make_edge(node(i, time - 1), node(i, time), 50);
^
user.cpp:14:5: error: initializing argument 2 of ‘int node(int, int)’ [-fpermissive]
int node(int x, int y)
^
user.cpp:81:45: warning: pointer to a function used in arithmetic [-Wpointer-arith]
make_edge(node(x[i], time - 1), node(y[i], time), c[i]);
^
user.cpp:81:43: error: invalid conversion from ‘time_t (*)(time_t*)throw () {aka long int (*)(long int*)throw ()}’ to ‘int’ [-fpermissive]
make_edge(node(x[i], time - 1), node(y[i], time), c[i]);
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !