01
# Include <stdio. h>
Int main ()
{
Int X1, Y1, X2, Y2, X3, Y3;
Double S;
While (scanf ("% d", & X1, & Y1, & X2, & Y2, & X3, & Y3) & X1 + X2 + X3 + Y1 + y2 + Y3)
{
S = x1 * y2 + X3 * Y1 + x2 * y3-x3 * y2-x2 * y1-x1 * Y3; // The Cross Product of AB and BC vectors ......
If (S <0) printf ("1 \ n ");
Else printf ("0 \ n ");
}
Return 0;
}
Length of the cross product | A × B | it can be interpreted as the area of the parallelogram with a and B as the adjacent edges.
# Include <stdio. h>
# Include <math. h>
Main ()
{
Int x1, x2, X3, Y1, Y2, Y3;
Double S;
While (scanf ("% d", & X1, & Y1, & X2, & Y2, & X3, & Y3 ))
{
If (x1 = 0 & Y1 = 0 & X2 = 0 & y2 = 0 & X3 = 0 & Y3 = 0) break;
S = (x2-x1) * (y3-y1)-(x3-x1) * (y2-y1)/2.0;
If (S> = 0)
Printf ("0 \ n ");
Else
Printf ("1 \ n ");
}
}
# Include <stdio. h>
# Include <math. h>
Main ()
{
Int x1, x2, X3, Y1, Y2, Y3;
Double S;
While (scanf ("% d", & X1, & Y1, & X2, & Y2, & X3, & Y3 ), (X1 | Y1 | X2 | Y2 | X3 | Y3 ))
{
S = (x2-x1) * (y3-y1)-(x3-x1) * (y2-y1)/2.0;
If (S> = 0)
Printf ("0 \ n ");
Else
Printf ("1 \ n ");
}
}
# Include <iostream>
Using namespace STD;
Int main ()
{
While (1)
{
Int X1, Y1, X2, Y2, X3, Y3;
Cin> x1> Y1> X2> Y2> X3> Y3;
If (x1 = 0 & Y1 = 0 & X2 = 0 & y2 = 0 & X3 = 0 & Y3 = 0) break;
Int AX = x2-x1, ay = y2-y1, BX = x2-x3, by = y2-y3;
If (ax * by-ay * BX <0)
Cout <0 <Endl;
Else
Cout <1 <Endl;
}
}