// gnc type3 #include #include #include using namespace std; struct Coord { int x, y; Coord(int a, int b):x(a),y(b){} }; int ccw(const Coord &c1, const Coord &c2, const Coord &c3) { int x1=c2.x-c1.x, x2 = c3.x-c1.x; int y1=c2.y-c1.y, y2 = c3.y-c1.y; return x1*y2-x2*y1; } int inner_prod(const Coord &c1, const Coord &c2, const Coord &c3) { int x1=c2.x-c1.x, x2 = c3.x-c1.x; int y1=c2.y-c1.y, y2 = c3.y-c1.y; return x1*x2+y1*y2; } int main(void) { int i, j, k, l; int x, y; int ncoord; int rec_area; int area; int rec[3]; ifstream fin("myacm.txt"); while ( fin>>ncoord && ncoord>0) { vector coords; for ( i=0 ; i>c>>x>>y; coords.push_back(Coord(x,y)); } rec_area = 0; for ( i=0 ; iarea ) continue; for ( l=0 ; l0 ) continue; else break; } if ( c2==0 ) { if ( inner_prod(coords[l],coords[j],coords[k])>0 ) continue; else break; } if ( c3==0 ) { if ( inner_prod(coords[l],coords[k],coords[i])>0 ) continue; else break; } if ( /*c1*c2*c3==0 ||*/ (c1*c2>0 && c2*c3>0) ) { break; } } if ( l!=ncoord ) continue; rec_area=area; rec[0]=i; rec[1]=j; rec[2]=k; } } } cout<<(char)('A'+rec[0])<<(char)('A'+rec[1])<<(char)('A'+rec[2])<