F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

View Compilation Error

0_0_16234796_12834.c:11:12: error: unknown type name 'point'
 double fun(point *arr, int m, int n);
            ^
0_0_16234796_12834.c:12:13: error: unknown type name 'point'
 double fun1(point *arr, int m, int n, int mid, double dmin);
             ^
0_0_16234796_12834.c:13:17: error: unknown type name 'point'
 double distance(point a, point b);
                 ^
0_0_16234796_12834.c:13:26: error: unknown type name 'point'
 double distance(point a, point b);
                          ^
0_0_16234796_12834.c: In function 'main':
0_0_16234796_12834.c:22:3: error: unknown type name 'point'
   point *arr;
   ^
0_0_16234796_12834.c:23:10: error: 'point' undeclared (first use in this function)
   arr = (point *) malloc (sizeof(point *) * n);
          ^
0_0_16234796_12834.c:23:10: note: each undeclared identifier is reported only once for each function it appears in
0_0_16234796_12834.c:23:17: error: expected expression before ')' token
   arr = (point *) malloc (sizeof(point *) * n);
                 ^
0_0_16234796_12834.c:25:3: error: 'for' loop initial declarations are only allowed in C99 or C11 mode
   for(int i=0; i<n; i++)
   ^
0_0_16234796_12834.c:25:3: note: use option -std=c99, -std=gnu99, -std=c11 or -std=gnu11 to compile your code
0_0_16234796_12834.c:26:26: error: request for member 'x' in something not a structure or union
    scanf("%lf%lf",&arr[i].x,&arr[i].y);
                          ^
0_0_16234796_12834.c:26:36: error: request for member 'y' in something not a structure or union
    scanf("%lf%lf",&arr[i].x,&arr[i].y);
                                    ^
0_0_16234796_12834.c:38:3: error: expected expression before '/' token
   //puts("\n----最小点距的一半为");
   ^
0_0_16234796_12834.c: At top level:
0_0_16234796_12834.c:45:12: error: unknown type name 'point'
 double fun(point arr[],int m,int n)
            ^
0_0_16234796_12834.c:86:13: error: unknown type name 'point'
 double fun1(point arr[],int m,int n,int mid,double dmin)
             ^
0_0_16234796_12834.c: In function 'Comp':
0_0_16234796_12834.c:114:2: error: unknown type name 'point'
  point *point1 = (point *)p1;
  ^
0_0_16234796_12834.c:114:19: error: 'point' undeclared (first use in this function)
  point *point1 = (point *)p1;
                   ^
0_0_16234796_12834.c:114:26: error: expected expression before ')' token
  point *point1 = (point *)p1;
                          ^
0_0_16234796_12834.c:115:9: error: 'point2' undeclared (first use in this function)
  point *point2 = (point *)p2;
         ^
0_0_16234796_12834.c:115:26: error: expected expression before ')' token
  point *point2 = (point *)p2;
                          ^
0_0_16234796_12834.c:117:14: error: request for member 'x' in something not a structure or union
  if((*point1).x != (*point2).x)
              ^
0_0_16234796_12834.c:118:19: error: request for member 'x' in something not a structure or union
   return (*point1).x > (*point2).x ? 1 : -1;
                   ^
0_0_16234796_12834.c:120:19: error: request for member 'y' in something not a structure or union
   return (*point1).y > (*point2).y ? 1 : -1;
                   ^
0_0_16234796_12834.c: At top level:
0_0_16234796_12834.c:123:17: error: unknown type name 'point'
 double distance(point a, point b)
                 ^
0_0_16234796_12834.c:123:26: error: unknown type name 'point'
 double distance(point a, point b)
                          ^


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2024 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2024-12-03 22:31:42, Gzip enabled