Submission #3014672
Source Code Expand
#include<cstdio> #include<iostream> #include<algorithm> #include<cmath> #include<map> #include<queue> #include<stack> #include<list> #include<set> #include<cstring> #include<string> using namespace std; int main(){ //freopen(".in","r",stdin); //freopen(".out","w",stdout); double a1,a2,b1,b2,s,x1,x2,x3,y1,y2,y3; scanf("%lf %lf %lf %lf %lf %lf",&x1,&y1,&x2,&y2,&x3,&y3); a1=x2-x1; a2=y2-yy; b1=x2-x3; b2=y2-y3; s=(a1*b2-a2*b1)/2; if(s<0) s=-s; printf("%.1lf\n",s); return 0; }
Submission Info
Submission Time | |
---|---|
Task | C - 直訴 |
User | luogu_bot5 |
Language | C++ (GCC 5.4.1) |
Score | 0 |
Code Size | 549 Byte |
Status | CE |
Compile Error
./Main.cpp: In function ‘int main()’: ./Main.cpp:19:11: error: ‘yy’ was not declared in this scope a2=y2-yy; ^ ./Main.cpp:17:61: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result] scanf("%lf %lf %lf %lf %lf %lf",&x1,&y1,&x2,&y2,&x3,&y3); ^