Borderou de evaluare (job #2604827)
Utilizator | Data | 23 aprilie 2020 16:42:23 | |
---|---|---|---|
Problema | Lowest Common Ancestor | Status | done |
Runda | Arhiva educationala | Compilator | cpp-64 | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
main.cpp:12:15: error: 'int time' redeclared as different kind of symbol
int n, m, nr, time, vf[N], urm[N], lst[N], t[L][N], tb[N], to[N];
^~~~
In file included from /usr/include/pthread.h:24:0,
from /usr/include/x86_64-linux-gnu/c++/6/bits/gthr-default.h:35,
from /usr/include/x86_64-linux-gnu/c++/6/bits/gthr.h:148,
from /usr/include/c++/6/ext/atomicity.h:35,
from /usr/include/c++/6/bits/ios_base.h:39,
from /usr/include/c++/6/ios:42,
from /usr/include/c++/6/ostream:38,
from /usr/include/c++/6/iostream:39,
from main.cpp:1:
/usr/include/time.h:192:15: note: previous declaration 'time_t time(time_t*)'
extern time_t time (time_t *__timer) __THROW;
^~~~
main.cpp: In function 'void dfs(int)':
main.cpp:22:12: warning: ISO C++ forbids incrementing a pointer of type 'time_t (*)(time_t*) throw () {aka long int (*)(long int*) throw ()}' [-Wpointer-arith]
tb[x] = ++time; //timpul de intrare
^~~~
main.cpp:22:12: error: lvalue required as increment operand
main.cpp:31:12: warning: ISO C++ forbids incrementing a pointer of type 'time_t (*)(time_t*) throw () {aka long int (*)(long int*) throw ()}' [-Wpointer-arith]
to[x] = ++time; // timpul de iesire
^~~~
main.cpp:31:12: error: lvalue required as increment operand
Non zero exit status: 1
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !