Borderou de evaluare (job #2854233)

Utilizator Ana-paciuAna Paciu Ana-paciu Data 21 februarie 2022 08:40:19
Problema Subsecventa de suma maxima Status done
Runda Arhiva educationala Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp: In function 'int main()': main.cpp:11:19: error: 'INT_MIN' was not declared in this scope 11 | int bestSum = INT_MIN, sum = 0, beg, endx, idx; | ^~~~~~~ main.cpp:4:1: note: 'INT_MIN' is defined in header '<climits>'; did you forget to '#include <climits>'? 3 | #include <algorithm> +++ |+#include <climits> 4 | using namespace std; main.cpp:15:13: error: 'sum' was not declared in this scope 15 | if (sum < 0) | ^~~ main.cpp:16:22: error: 'idx' was not declared in this scope 16 | sum = S, idx = i; | ^~~ main.cpp:19:23: error: 'sum' was not declared in this scope 19 | if (bestSum < sum) | ^~~ main.cpp:20:28: error: 'beg' was not declared in this scope 20 | bestSum = sum, beg = idx, endx = i; | ^~~ main.cpp:20:34: error: 'idx' was not declared in this scope 20 | bestSum = sum, beg = idx, endx = i; | ^~~ main.cpp:20:39: error: 'endx' was not declared in this scope 20 | bestSum = sum, beg = idx, endx = i; | ^~~~ main.cpp:23:31: error: 'beg' was not declared in this scope 23 | fout << bestSum << " " << beg << " " << endx; | ^~~ main.cpp:23:45: error: 'endx' was not declared in this scope 23 | fout << bestSum << " " << beg << " " << endx; | ^~~~ Non zero exit status: 1

Ceva nu functioneaza?