Borderou de evaluare (job #2105904)

Utilizator inquisitorAnders inquisitor Data 14 ianuarie 2018 16:39:05
Problema Figuri Status done
Runda Arhiva de probleme Compilator cpp | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: user.cpp:3:25: error: ‘short int y1’ redeclared as different kind of symbol short L, C, shapes, x1, y1, x2, y2, color, paper[201][201], ^ In file included from /usr/include/features.h:357:0, from /usr/include/assert.h:37, from /usr/include/c++/4.8/cassert:43, from /usr/include/i386-linux-gnu/c++/4.8/bits/stdc++.h:33, 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 BFS(std::pair<short int, short int>)’: user.cpp:41:18: warning: suggest parentheses around comparison in operand of ‘&’ [-Wparentheses] if(I > 0 & I <= L & J >= 0 & J < C & ^ user.cpp:41:35: warning: suggest parentheses around comparison in operand of ‘&’ [-Wparentheses] if(I > 0 & I <= L & J >= 0 & J < C & ^ user.cpp:41:44: warning: suggest parentheses around comparison in operand of ‘&’ [-Wparentheses] if(I > 0 & I <= L & J >= 0 & J < C & ^ user.cpp:42:28: warning: suggest parentheses around comparison in operand of ‘&’ [-Wparentheses] paper[I][J] == color & !visited[I][J]) ^ user.cpp: In function ‘int main()’: user.cpp:63:64: warning: format ‘%hd’ expects argument of type ‘short int*’, but argument 3 has type ‘double (*)(double)throw ()’ [-Wformat=] scanf("%hd %hd %hd %hd %hd", &x1, &y1, &x2, &y2, &color); ^ user.cpp:65:45: error: invalid operands of types ‘int’ and ‘double(double)throw ()’ to binary ‘operator-’ DrawShape((C >> 1) + x1, (L >> 1) - y1, (C >> 1) + x2, (L >> 1) - y2, ~-color); ^ user.cpp:56:37: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result] freopen("figuri.in", "r", stdin); ^ user.cpp:57:39: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result] freopen("figuri.out", "w", stdout); ^ user.cpp:59:42: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result] scanf("%hd %hd %hd", &C, &L, &shapes); ^ user.cpp:63:65: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result] scanf("%hd %hd %hd %hd %hd", &x1, &y1, &x2, &y2, &color); ^

Ceva nu functioneaza?