Borderou de evaluare (job #1647589)

Utilizator Andrei1998Andrei Constantinescu Andrei1998 Data 10 martie 2016 21:14:49
Problema Project management Status done
Runda Arhiva de probleme Compilator cpp | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: user.cpp:10:14: error: ‘int time [105]’ redeclared as different kind of symbol int time[NMAX]; ^ 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/istream:38, from /usr/include/c++/4.8/fstream:38, 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 ‘void dfs1(int)’: user.cpp:23:77: warning: pointer to a function used in arithmetic [-Wpointer-arith] minim_start[node] = max(minim_start[node], minim_start[it] + time[it]); ^ user.cpp:23:77: warning: pointer to a function used in arithmetic [-Wpointer-arith] user.cpp:23:78: error: no matching function for call to ‘max(int&, time_t (*)(time_t*)throw ())’ minim_start[node] = max(minim_start[node], minim_start[it] + time[it]); ^ user.cpp:23:78: note: candidates are: In file included from /usr/include/c++/4.8/bits/char_traits.h:39:0, from /usr/include/c++/4.8/ios:40, from /usr/include/c++/4.8/istream:38, from /usr/include/c++/4.8/fstream:38, from user.cpp:1: /usr/include/c++/4.8/bits/stl_algobase.h:216:5: note: template<class _Tp> const _Tp& std::max(const _Tp&, const _Tp&) max(const _Tp& __a, const _Tp& __b) ^ /usr/include/c++/4.8/bits/stl_algobase.h:216:5: note: template argument deduction/substitution failed: user.cpp:23:78: note: deduced conflicting types for parameter ‘const _Tp’ (‘int’ and ‘time_t (*)(time_t*)throw () {aka long int (*)(long int*)throw ()}’) minim_start[node] = max(minim_start[node], minim_start[it] + time[it]); ^ In file included from /usr/include/c++/4.8/bits/char_traits.h:39:0, from /usr/include/c++/4.8/ios:40, from /usr/include/c++/4.8/istream:38, from /usr/include/c++/4.8/fstream:38, from user.cpp:1: /usr/include/c++/4.8/bits/stl_algobase.h:260:5: note: template<class _Tp, class _Compare> const _Tp& std::max(const _Tp&, const _Tp&, _Compare) max(const _Tp& __a, const _Tp& __b, _Compare __comp) ^ /usr/include/c++/4.8/bits/stl_algobase.h:260:5: note: template argument deduction/substitution failed: user.cpp:23:78: note: deduced conflicting types for parameter ‘const _Tp’ (‘int’ and ‘time_t (*)(time_t*)throw () {aka long int (*)(long int*)throw ()}’) minim_start[node] = max(minim_start[node], minim_start[it] + time[it]); ^ In file included from /usr/include/c++/4.8/algorithm:62:0, from user.cpp:2:

Ceva nu functioneaza?