Borderou de evaluare (job #2145493)

Utilizator akaprosAna Kapros akapros Data 27 februarie 2018 13:30:14
Problema Xor3 Status done
Runda Arhiva de probleme Compilator cpp | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: user.cpp:10:12: error: ‘int j1’ redeclared as different kind of symbol int Q, i1, j1, a, b, m; ^ In file included from /usr/include/features.h:367:0, from /usr/include/assert.h:35, from /usr/include/c++/5/cassert:43, from /usr/include/x86_64-linux-gnu/c++/5/bits/stdc++.h:33, from user.cpp:1: /usr/include/x86_64-linux-gnu/bits/mathcalls.h:248:1: note: previous declaration ‘double j1(double)’ __MATHCALL (j1,, (_Mdouble_)); ^ user.cpp: In function ‘void brut()’: user.cpp:31:34: error: invalid types ‘int [1002][double(double) throw ()]’ for array subscript printf("%d\n", mat[i1][j1]); ^ user.cpp:33:19: error: invalid operands of types ‘int’ and ‘double(double) throw ()’ to binary ‘operator*’ j1 = (a * j1 + b) % m; ^ user.cpp: In function ‘void brut2()’: user.cpp:62:34: error: invalid conversion from ‘double (*)(double) throw ()’ to ‘int’ [-fpermissive] printf("%d\n", Xor(i1, j1)); ^ user.cpp:36:5: note: initializing argument 2 of ‘int Xor(int, int)’ int Xor(int x, int y) ^ user.cpp:64:19: error: invalid operands of types ‘int’ and ‘double(double) throw ()’ to binary ‘operator*’ j1 = (a * j1 + b) % m; ^ user.cpp: In function ‘int main()’: user.cpp:69:51: warning: format ‘%d’ expects argument of type ‘int*’, but argument 4 has type ‘double (*)(double) throw ()’ [-Wformat=] scanf("%d%d%d%d%d%d", &Q, &i1, &j1, &a, &b, &m); ^ user.cpp: In function ‘int Xor(int, int)’: user.cpp:57:1: warning: control reaches end of non-void function [-Wreturn-type] } ^ user.cpp: In function ‘int main()’: user.cpp:69:52: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result] scanf("%d%d%d%d%d%d", &Q, &i1, &j1, &a, &b, &m); ^

Ceva nu functioneaza?