foo.c: In function 'main':
foo.c:24:28: warning: implicit declaration of function 'strlen' [-Wimplicit-function-declaration]
p = (char *)malloc(strlen(A) + strlen(B));
^~~~~~
foo.c:24:28: warning: incompatible implicit declaration of built-in function 'strlen'
foo.c:24:28: note: include '<string.h>' or provide a declaration of 'strlen'
foo.c:25:9: warning: implicit declaration of function 'strcpy' [-Wimplicit-function-declaration]
strcpy(p, B);
^~~~~~
foo.c:25:9: warning: incompatible implicit declaration of built-in function 'strcpy'
foo.c:25:9: note: include '<string.h>' or provide a declaration of 'strcpy'
foo.c:26:9: warning: implicit declaration of function 'strcat' [-Wimplicit-function-declaration]
strcat(p, A);
^~~~~~
foo.c:26:9: warning: incompatible implicit declaration of built-in function 'strcat'
foo.c:26:9: note: include '<string.h>' or provide a declaration of 'strcat'
foo.c:12:5: warning: ignoring return value of 'scanf', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d", &n);
^~~~~~~~~~~~~~~
foo.c:17:5: warning: ignoring return value of 'scanf', declared with attribute warn_unused_result [-Wunused-result]
scanf("%s", s1);
^~~~~~~~~~~~~~~
foo.c:18:5: warning: ignoring return value of 'scanf', declared with attribute warn_unused_result [-Wunused-result]
scanf("%s", s2);
^~~~~~~~~~~~~~~
[Hydro](https://hydro.ac)提供评测服务