Borderou de evaluare (job #2883150)

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

Raport evaluator

Eroare de compilare: main.cpp:6:31: error: 'int j1' redeclared as different kind of entity 6 | 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:18:7: error: assignment of function 'double j1(double)' 18 | j1=0; | ~~^~ main.cpp:23:14: error: invalid types 'long long int [3][100001][double(double) throw () {aka double(double)}]' for array subscript 23 | D[j1][i]=1e18; | ^ main.cpp:25:23: error: invalid operands of types 'int' and 'double(double) throw ()' {aka 'double(double)'} to binary 'operator-' 25 | if(D[1-j1][p]+abs(s-(S[i]-S[p]))<D[j1][i]) | ~^~~ | | | | | double(double) throw () {aka double(double)} | int main.cpp:25:51: error: invalid types 'long long int [3][100001][double(double) throw () {aka double(double)}]' for array subscript 25 | if(D[1-j1][p]+abs(s-(S[i]-S[p]))<D[j1][i]) | ^ main.cpp:26:22: error: invalid types 'long long int [3][100001][double(double) throw () {aka double(double)}]' for array subscript 26 | D[j1][i]=D[1-j1][p]+abs(s-(S[i]-S[p])); | ^ main.cpp:26:33: error: invalid operands of types 'int' and 'double(double) throw ()' {aka 'double(double)'} to binary 'operator-' 26 | D[j1][i]=D[1-j1][p]+abs(s-(S[i]-S[p])); | ~^~~ | | | | | double(double) throw () {aka double(double)} | int main.cpp:28:16: error: invalid types 'long long int [3][100001][double(double) throw () {aka double(double)}]' for array subscript 28 | fout<<D[j1][n]<<" "; | ^ main.cpp:29:13: error: invalid operands of types 'int' and 'double(double) throw ()' {aka 'double(double)'} to binary 'operator-' 29 | j1=1-j1; | ~^~~ | | | | | double(double) throw () {aka double(double)} | int Non zero exit status: 1

Ceva nu functioneaza?