fork download
  1. #include <stdio.h>
  2. #include <stdlib.h>
  3.  
  4. int no_search(int a[],int n,int x);
  5. int no_search(int a[],int n,int x){
  6. int ret=-1;
  7. return ret;
  8. }
  9. int main(void) {
  10. int n,x,i;
  11. int *a;
  12. int ans=-1;
  13. scanf("%d,%d",&n,&x);
  14. a=(int *)malloc(sizeof(int)*n);
  15. for(i=0; i<ans; i++){
  16. scanf("%d",a[i]);
  17. if(a[ans]==NULL){
  18. printf("ERROR\n");
  19. return -1;
  20. }
  21. }
  22.  
  23. no_search(a,n,x);
  24. if(ans!=-1) printf("%d\n",a[ans]);
  25. else printf("not found");
  26. free(a);
  27. return 0;
  28. }
  29.  
Success #stdin #stdout 0s 5272KB
stdin
Standard input is empty
stdout
not found