Borderou de evaluare (job #1399365)

Utilizator BlueStrutAndrei Prahoveanu BlueStrut Data 24 martie 2015 18:31:20
Problema Barbar Status done
Runda Arhiva de probleme Compilator cpp | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: user.cpp:9:61: error: ‘int y1’ redeclared as different kind of symbol int i, j, n, m, x, y, a[1002][1002], b[1002][1002], x1, x2, y1, y2, st, dr, mij, k, sol; ^ In file included from /usr/include/features.h:357:0, from /usr/include/i386-linux-gnu/c++/4.8/bits/os_defines.h:39, from /usr/include/i386-linux-gnu/c++/4.8/bits/c++config.h:420, from /usr/include/c++/4.8/cstdio:41, 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 ‘bool test(int)’: user.cpp:15:46: error: no matching function for call to ‘std::deque<std::pair<int, int> >::push_back(std::pair<int, double (*)(double)throw ()>)’ cd.clear(); cd.push_back(make_pair(x1,y1)); b[x1][y1]=0; ^ user.cpp:15:46: note: candidates are: In file included from /usr/include/c++/4.8/deque:64:0, from user.cpp:3: /usr/include/c++/4.8/bits/stl_deque.h:1390:7: note: void std::deque<_Tp, _Alloc>::push_back(const value_type&) [with _Tp = std::pair<int, int>; _Alloc = std::allocator<std::pair<int, int> >; std::deque<_Tp, _Alloc>::value_type = std::pair<int, int>] push_back(const value_type& __x) ^ /usr/include/c++/4.8/bits/stl_deque.h:1390:7: note: no known conversion for argument 1 from ‘std::pair<int, double (*)(double)throw ()>’ to ‘const value_type& {aka const std::pair<int, int>&}’ /usr/include/c++/4.8/bits/stl_deque.h:1404:7: note: void std::deque<_Tp, _Alloc>::push_back(std::deque<_Tp, _Alloc>::value_type&&) [with _Tp = std::pair<int, int>; _Alloc = std::allocator<std::pair<int, int> >; std::deque<_Tp, _Alloc>::value_type = std::pair<int, int>] push_back(value_type&& __x) ^ /usr/include/c++/4.8/bits/stl_deque.h:1404:7: note: no known conversion for argument 1 from ‘std::pair<int, double (*)(double)throw ()>’ to ‘std::deque<std::pair<int, int> >::value_type&& {aka std::pair<int, int>&&}’ user.cpp:15:57: error: invalid types ‘int [1002][double(double)throw ()]’ for array subscript cd.clear(); cd.push_back(make_pair(x1,y1)); b[x1][y1]=0; ^ user.cpp: In function ‘int main()’: user.cpp:37:58: error: assignment of function ‘double y1(double)’ if (s[j]=='I') {a[i][j+1]=999999999; x1=i; y1=j+1;} ^ user.cpp:37:58: error: cannot convert ‘int’ to ‘double(double)throw ()’ in assignment user.cpp:51:17: error: invalid types ‘int [1002][double(double)throw ()]’ for array subscript if (a[x1][y1]<a[x2][y2]) st=dr-a[x2][y2]; else st=dr-a[x1][y1]; sol=-1; ^ user.cpp:51:66: error: invalid types ‘int [1002][double(double)throw ()]’ for array subscript if (a[x1][y1]<a[x2][y2]) st=dr-a[x2][y2]; else st=dr-a[x1][y1]; sol=-1; ^ user.cpp:27:35: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result] freopen("barbar.in","r",stdin); ^ user.cpp:28:37: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result] freopen("barbar.out","w",stdout); ^ user.cpp:29:28: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result] scanf("%d%d\n", &n, &m); ^ user.cpp:33:16: warning: ignoring return value of ‘char* gets(char*)’, declared with attribute warn_unused_result [-Wunused-result]

Ceva nu functioneaza?