foo.c: In function 'main':
foo.c:11:16: error: 'max' undeclared (first use in this function); did you mean 'main'?
printf("%d",max);
^~~
main
foo.c:11:16: note: each undeclared identifier is reported only once for each function it appears in
foo.c: In function 'zuidazhi':
foo.c:31:29: warning: passing argument 1 of 'zuidazhi' makes pointer from integer without a cast [-Wint-conversion]
max=(a[n-1]>zuidazhi(n-1)?a[n-1]:zuidazhi(n-1));
^
foo.c:22:5: note: expected 'int *' but argument is of type 'int'
int zuidazhi(int a[],int n)
^~~~~~~~
foo.c:31:20: error: too few arguments to function 'zuidazhi'
max=(a[n-1]>zuidazhi(n-1)?a[n-1]:zuidazhi(n-1));
^~~~~~~~
foo.c:22:5: note: declared here
int zuidazhi(int a[],int n)
^~~~~~~~
foo.c:31:50: warning: passing argument 1 of 'zuidazhi' makes pointer from integer without a cast [-Wint-conversion]
max=(a[n-1]>zuidazhi(n-1)?a[n-1]:zuidazhi(n-1));
^
foo.c:22:5: note: expected 'int *' but argument is of type 'int'
int zuidazhi(int a[],int n)
^~~~~~~~
foo.c:31:41: error: too few arguments to function 'zuidazhi'
max=(a[n-1]>zuidazhi(n-1)?a[n-1]:zuidazhi(n-1));
^~~~~~~~
foo.c:22:5: note: declared here
int zuidazhi(int a[],int n)
^~~~~~~~
foo.c: In function 'main':
foo.c:6:4: warning: ignoring return value of 'scanf', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d",&n);
^~~~~~~~~~~~~~
foo.c: In function 'shuru':
foo.c:19:9: warning: ignoring return value of 'scanf', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d",&a[i]);
^~~~~~~~~~~~~~~~~
[Hydro](https://hydro.ac)提供评测服务