Borderou de evaluare (job #2956437)

Utilizator valentina2004Stan Valentina valentina2004 Data 19 decembrie 2022 15:51:43
Problema Subsecventa de suma maxima Status done
Runda Arhiva educationala Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp:5:7: error: 'INF' does not name a type 5 | const INF = 2e9; | ^~~ main.cpp: In function 'int main()': main.cpp:9:16: error: variable 'std::ifstream in' has initializer but incomplete type 9 | ifstream in("ssm.in"); | ^ main.cpp:10:17: error: variable 'std::ofstream out' has initializer but incomplete type 10 | ofstream out("ssm.out");3 | ^ main.cpp:10:30: error: expected ';' before 'int' 10 | ofstream out("ssm.out");3 | ^ | ; 11 | int n, sc = -1, smax = -INF, poz, st, dr; | ~~~ main.cpp:10:29: warning: statement has no effect [-Wunused-value] 10 | ofstream out("ssm.out");3 | ^ main.cpp:12:11: error: 'n' was not declared in this scope 12 | in >> n; | ^ main.cpp:17:19: error: 'sc' was not declared in this scope 17 | if (x_i > sc + x_i) | ^~ main.cpp:20:13: error: 'poz' was not declared in this scope 20 | poz = i; | ^~~ main.cpp:26:13: error: 'sc' was not declared in this scope 26 | if (sc > smax) | ^~ main.cpp:26:18: error: 'smax' was not declared in this scope 26 | if (sc > smax) | ^~~~ main.cpp:29:13: error: 'st' was not declared in this scope; did you mean 'std'? 29 | st = poz; | ^~ | std main.cpp:29:18: error: 'poz' was not declared in this scope 29 | st = poz; | ^~~ main.cpp:30:13: error: 'dr' was not declared in this scope 30 | dr = i; | ^~ main.cpp:33:12: error: 'smax' was not declared in this scope 33 | out << smax << " " << st << " " << dr; | ^~~~ main.cpp:33:27: error: 'st' was not declared in this scope; did you mean 'std'? 33 | out << smax << " " << st << " " << dr; | ^~ Non zero exit status: 1

Ceva nu functioneaza?