foo.c: In function 'Output':
foo.c:5:17: warning: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
5 | printf("%d ", a[i]);
| ^~~~~~
foo.c:1:1: note: include '<stdio.h>' or provide a declaration of 'printf'
+++ |+#include <stdio.h>
1 | void Output(int a[], int n)
foo.c:5:17: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
5 | printf("%d ", a[i]);
| ^~~~~~
foo.c:5:17: note: include '<stdio.h>' or provide a declaration of 'printf'
foo.c:7:9: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
7 | printf("\n");
| ^~~~~~
foo.c:7:9: note: include '<stdio.h>' or provide a declaration of 'printf'
foo.c: In function 'Search':
foo.c:13:21: warning: suggest parentheses around assignment used as truth value [-Wparentheses]
13 | if (a[i] = x)
| ^
foo.c: In function 'main':
foo.c:50:9: warning: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
50 | scanf("%d%d%d", &n1, &n2, &n3);
| ^~~~~
foo.c:50:9: note: include '<stdio.h>' or provide a declaration of 'scanf'
foo.c:50:9: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch]
foo.c:50:9: note: include '<stdio.h>' or provide a declaration of 'scanf'
[Hydro](https://hydro.ac)提供评测服务