foo.c: In function 'main':
foo.c:5:25: warning: unused variable 't' [-Wunused-variable]
int i,j=0,n,k,a[10000],t;
^
foo.c:6:2: warning: ignoring return value of 'scanf', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d%d",&n,&k);
^~~~~~~~~~~~~~~~~~~
foo.c:8:3: warning: ignoring return value of 'scanf', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d",&a[i]);
^~~~~~~~~~~~~~~~~
foo.c:28:8: warning: 'index' may be used uninitialized in this function [-Wmaybe-uninitialized]
a[j]=a[index];
^
foo.c:22:19: note: 'index' was declared here
int t,i,min=a[j],index;
^~~~~
foo.c: In function 'min':
foo.c:28:8: warning: 'index' may be used uninitialized in this function [-Wmaybe-uninitialized]
a[j]=a[index];
^
[Hydro](https://hydro.ac)提供评测服务