Borderou de evaluare (job #789591)

Utilizator avatar emavalv Ema Valvoi emavalv IP ascuns
Problemă Crioac (clasa a 5-a) Compilator cpp-32
Rundă Arhiva de probleme Status evaluat
Dată 12 oct. 2024 19:01:01 Scor 0

Raport evaluator

Eroare de compilare: main.cpp: In function 'int main()': main.cpp:14:9: error: 'x' was not declared in this scope 14 | g=g+x; | ^ main.cpp:18:9: error: 'y' was not declared in this scope 18 | b=b-y; | ^ main.cpp:23:3: warning: this 'else' clause does not guard... [-Wmisleading-indentation] 23 | else | ^~~~ main.cpp:25:5: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'else' 25 | g=1; | ^ main.cpp:28:8: error: 'x' was not declared in this scope 28 | g= g+x; | ^ main.cpp:29:7: error: 'y' was not declared in this scope 29 | b=b-y; | ^ main.cpp:32:5: error: 'cout' was not declared in this scope 32 | cout<<g; | ^~~~ main.cpp:3:1: note: 'std::cout' is defined in header '<iostream>'; did you forget to '#include <iostream>'? 2 | #include <fstream> +++ |+#include <iostream> 3 | main.cpp:31:1: warning: this 'if' clause does not guard... [-Wmisleading-indentation] 31 | if( g==b) | ^~ main.cpp:34:5: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'if' 34 | return 0; | ^~~~~~ main.cpp:10:21: warning: unused variable 'K' [-Wunused-variable] 10 | int N, X,Y, g= 1, K, D, c=0, d=0; | ^ main.cpp:10:24: warning: unused variable 'D' [-Wunused-variable] 10 | int N, X,Y, g= 1, K, D, c=0, d=0; | ^