Borderou de evaluare (job #1762536)

Utilizator Dan_RadulescuRadulescu Dan Dan_Radulescu Data 23 septembrie 2016 18:19:20
Problema Reuniune Status done
Runda Arhiva de probleme Compilator cpp | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: user.cpp:6:21: error: ‘long long int y1 [3]’ redeclared as different kind of symbol long long x1[3],y1[3],x2[3],y2[3],xr1,yr1,xr2,yr2,arie,perim,i,sw=0; ^ In file included from /usr/include/features.h:357:0, from /usr/include/stdio.h:28, from user.cpp:1: /usr/include/i386-linux-gnu/bits/mathcalls.h:243:1: error: previous declaration of ‘double y1(double)’ __MATHCALL (y1,, (_Mdouble_)); ^ user.cpp: In function ‘void intersectie(int, int)’: user.cpp:8:19: warning: pointer to a function used in arithmetic [-Wpointer-arith] if (y2[i]<y1[j]) { ^ user.cpp:8:19: error: ISO C++ forbids comparison between pointer and integer [-fpermissive] user.cpp:12:13: warning: pointer to a function used in arithmetic [-Wpointer-arith] if (y1[i]>y2[j]) { ^ user.cpp:12:19: error: ISO C++ forbids comparison between pointer and integer [-fpermissive] if (y1[i]>y2[j]) { ^ user.cpp:25:17: warning: pointer to a function used in arithmetic [-Wpointer-arith] yr1=max(y1[i],y1[j]); ^ user.cpp:25:23: warning: pointer to a function used in arithmetic [-Wpointer-arith] yr1=max(y1[i],y1[j]); ^ user.cpp:25:8: error: invalid conversion from ‘double (*)(double)throw ()’ to ‘long long int’ [-fpermissive] yr1=max(y1[i],y1[j]); ^ user.cpp: In function ‘void intersectie3()’: user.cpp:34:17: warning: pointer to a function used in arithmetic [-Wpointer-arith] if (yr2<y1[0]) { ^ user.cpp:34:17: error: ISO C++ forbids comparison between pointer and integer [-fpermissive] user.cpp:47:21: warning: pointer to a function used in arithmetic [-Wpointer-arith] y1f=max(yr1,y1[0]); ^ user.cpp:47:22: error: no matching function for call to ‘max(long long int&, double (&)(double)throw ())’ y1f=max(yr1,y1[0]); ^ user.cpp:47:22: note: candidates are: In file included from /usr/include/c++/4.8/algorithm:61:0, from user.cpp:2: /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:47:22: note: deduced conflicting types for parameter ‘const _Tp’ (‘long long int’ and ‘double(double)throw ()’) y1f=max(yr1,y1[0]); ^

Ceva nu functioneaza?