Borderou de evaluare (job #1780197)
Utilizator | Data | 15 octombrie 2016 22:11:05 | |
---|---|---|---|
Problema | Aria | Status | done |
Runda | Arhiva educationala | Compilator | cpp | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.cpp:5:18: error: ‘double y1’ redeclared as different kind of symbol
double ans,x1,x2,y1,y2;
^
In file included from /usr/include/features.h:357:0,
from /usr/include/i386-linux-gnu/c++/4.8/bits/os_defines.h:39,
from /usr/include/i386-linux-gnu/c++/4.8/bits/c++config.h:420,
from /usr/include/c++/4.8/cstdio:41,
from user.cpp:1:
/usr/include/i386-linux-gnu/bits/mathcalls.h:243:1: error: previous declaration of ‘double y1(double)’
__MATHCALL (y1,, (_Mdouble_));
^
user.cpp: In function ‘int main()’:
user.cpp:13:27: warning: format ‘%lf’ expects argument of type ‘double*’, but argument 3 has type ‘double (*)(double)throw ()’ [-Wformat=]
scanf("%lf%lf",&x1,&y1);
^
user.cpp:15:7: error: cannot convert ‘double(double)throw ()’ to ‘double’ in assignment
yy=y1;
^
user.cpp:19:27: error: invalid operands of types ‘double’ and ‘double(double)throw ()’ to binary ‘operator*’
ans+=x1*y2-x2*y1;
^
user.cpp:21:15: error: assignment of function ‘double y1(double)’
y1=y2;
^
user.cpp:21:15: error: cannot convert ‘double’ to ‘double(double)throw ()’ in assignment
user.cpp:23:19: error: invalid operands of types ‘double’ and ‘double(double)throw ()’ to binary ‘operator*’
ans+=x1*yy-xx*y1;
^
user.cpp:8:33: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
freopen("aria.in","r",stdin);
^
user.cpp:9:35: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
freopen("aria.out","w",stdout);
^
user.cpp:12:19: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%d",&n);
^
user.cpp:13:28: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%lf%lf",&x1,&y1);
^
user.cpp:18:36: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%lf%lf",&x2,&y2);
^
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !