[Warning] passing argument 1 of 'strcat' makes pointer from integer without a cast
THIS ERROR IS COMING WHEN I AM USING STRCAT WHAT SHOULD I DO , below is my code
#include <stdio.h>
#include <string.h>
void main() {
char a[20], b[256], p = NULL, f;
int i, j, n, k, c[20], t, x, l;
printf("enter the no of possible characters");
scanf("%d", &k);
printf("enter the possible characters in the dictionary");
printf("hi");
for (i = 0; i < k; i++) {
c[i] = (i);
a[i] = getchar();
}
for (i = 0; i < k; i++) {
printf("%d %s\n ", c[i], a[i]);
}
l = k;
printf("enter the string\n");
scanf("%s", &b);
n = strlen(b);
printf("%d", n);
for (i = 0; i < n; i++) {
strcat(p, b[i]);
}
getch();
}