AtCoder Beginner Contest 002

Submission #3014672

Source codeソースコード

#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

Task問題 C - 直訴
User nameユーザ名 luogu_bot5
Created time投稿日時
Language言語 C++ (GCC 5.4.1)
Status状態 CE
Score得点 -
Source lengthソースコード長 549 Byte
File nameファイル名
Exec time実行時間 -
Memory usageメモリ使用量 -

Compiler messageコンパイルメッセージ

./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);
^

Test case