Borderou de evaluare (job #2883149)

Utilizator Theo20067Cismaru Theodor-Alexe Theo20067 Data 1 aprilie 2022 10:58:55
Problema Secvbest Status done
Runda Arhiva de probleme Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp:7:31: error: 'int j1' redeclared as different kind of entity 7 | int i,j,k,n,s,p,minim,poz,sol,j1; | ^~ In file included from /usr/include/features.h:461, from /usr/include/x86_64-linux-gnu/c++/10/bits/os_defines.h:39, from /usr/include/x86_64-linux-gnu/c++/10/bits/c++config.h:522, from /usr/include/c++/10/iosfwd:38, from /usr/include/c++/10/ios:38, from /usr/include/c++/10/istream:38, from /usr/include/c++/10/fstream:38, from main.cpp:1: /usr/include/x86_64-linux-gnu/bits/mathcalls.h:218:1: note: previous declaration 'double j1(double)' 218 | __MATHCALL (j1,, (_Mdouble_)); | ^~~~~~~~~~ main.cpp: In function 'int main()': main.cpp:19:7: error: assignment of function 'double j1(double)' 19 | j1=0; | ~~^~ main.cpp:24:14: error: invalid types 'long long int [3][100001][double(double) throw () {aka double(double)}]' for array subscript 24 | D[j1][i]=1e18; | ^ main.cpp:26:23: error: invalid operands of types 'int' and 'double(double) throw ()' {aka 'double(double)'} to binary 'operator-' 26 | if(D[1-j1][p]+abs(s-(S[i]-S[p]))<D[j1][i]) | ~^~~ | | | | | double(double) throw () {aka double(double)} | int main.cpp:26:51: error: invalid types 'long long int [3][100001][double(double) throw () {aka double(double)}]' for array subscript 26 | if(D[1-j1][p]+abs(s-(S[i]-S[p]))<D[j1][i]) | ^ main.cpp:27:22: error: invalid types 'long long int [3][100001][double(double) throw () {aka double(double)}]' for array subscript 27 | D[j1][i]=D[1-j1][p]+abs(s-(S[i]-S[p])); | ^ main.cpp:27:33: error: invalid operands of types 'int' and 'double(double) throw ()' {aka 'double(double)'} to binary 'operator-' 27 | D[j1][i]=D[1-j1][p]+abs(s-(S[i]-S[p])); | ~^~~ | | | | | double(double) throw () {aka double(double)} | int main.cpp:29:16: error: invalid types 'long long int [3][100001][double(double) throw () {aka double(double)}]' for array subscript 29 | fout<<D[j1][n]<<" "; | ^ main.cpp:30:13: error: invalid operands of types 'int' and 'double(double) throw ()' {aka 'double(double)'} to binary 'operator-' 30 | j1=1-j1; | ~^~~ | | | | | double(double) throw () {aka double(double)} | int Non zero exit status: 1

Ceva nu functioneaza?