Borderou de evaluare (job #841701)

Utilizator avatar www_www Veveriță Tudor www_www IP ascuns
Problemă Romb2 (clasele 9-10) Compilator cpp
Rundă lasm_13_11_2025_clasa11 Status evaluat
Dată 13 nov. 2025 23:28:40 Scor 0

Raport evaluator

Eroare de compilare: main.cpp:5:28: error: 'double y1' redeclared as different kind of entity 5 | double qx, qy, cx, cy, x1, y1, x2, y2, x3, y3, x4, y4; | ^~ In file included from /usr/include/features.h:524, from /usr/lib/gcc/x86_64-pc-linux-gnu/14/include/g++-v14/x86_64-pc-linux-gnu/bits/os_defines.h:39, from /usr/lib/gcc/x86_64-pc-linux-gnu/14/include/g++-v14/x86_64-pc-linux-gnu/bits/c++config.h:683, from /usr/lib/gcc/x86_64-pc-linux-gnu/14/include/g++-v14/cassert:43, from /usr/lib/gcc/x86_64-pc-linux-gnu/14/include/g++-v14/x86_64-pc-linux-gnu/bits/stdc++.h:33, from main.cpp:1: /usr/include/bits/mathcalls.h:257:1: note: previous declaration 'double y1(double)' 257 | __MATHCALL (y1,, (_Mdouble_)); | ^~~~~~~~~~ main.cpp: In function 'int main()': main.cpp:33:25: error: assignment of function 'double y1(double)' 33 | x1 = cx; y1 = cy + hy; | ~~~^~~~~~~~~ main.cpp:37:25: error: cannot convert 'double (*)(double) noexcept' {aka 'double (*)(double)'} to 'double' 37 | dA = lineErr(x1, y1, x2, y2, qx, qy); | ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~ | | | double (*)(double) noexcept {aka double (*)(double)} main.cpp:9:34: note: initializing argument 2 of 'double lineErr(double, double, double, double, double, double)' 9 | double lineErr(double ax, double ay, double bx, double by, double px, double py) { | ~~~~~~~^~ main.cpp:40:25: error: cannot convert 'double (*)(double) noexcept' {aka 'double (*)(double)'} to 'double' 40 | dD = lineErr(x4, y4, x1, y1, qx, qy); | ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~ | | | double (*)(double) noexcept {aka double (*)(double)} main.cpp:9:56: note: initializing argument 4 of 'double lineErr(double, double, double, double, double, double)' 9 | double lineErr(double ax, double ay, double bx, double by, double px, double py) { | ~~~~~~~^~ main.cpp:48:46: error: cannot convert 'double(double) noexcept' {aka 'double(double)'} to 'double' in assignment 48 | if (choice == 1) { cx = x1; cy = y1; ans += 0 * block; } | ^~ | | | double(double) noexcept {aka double(double)} main.cpp:20:12: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)' declared with attribute 'warn_unused_result' [-Wunused-result] 20 | freopen("romb2.in", "r", stdin); | ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~ main.cpp:21:12: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)' declared with attribute 'warn_unused_result' [-Wunused-result] 21 | freopen("romb2.out", "w", stdout); | ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~