标签:
链接http://acm.swust.edu.cn/problem/203/
#include <stdio.h> int main() { double x1,x2,x3,y1,y2,y3; double s; while(~scanf("%lf %lf %lf %lf %lf %lf",&x1,&y1,&x2,&y2,&x3,&y3)) { s=(x1*y2+x2*y3+x3*y1-x1*y3-x2*y1-x3*y2)*1.0/2; if(s>=0) { printf("%0.1lf\n",s); } else { s=-s; printf("%0.1lf\n",s); } } return 0; }
<swustoj>?id=203 Jack's problem
标签:
原文地址:http://www.cnblogs.com/niconiconi/p/5721598.html