When I am trying to use the strcpy function the visual studio gives me an error
strcpy
error C4996: \'strcpy\': This function or variable may be unsafe. Co
The header definiton for C is:
errno_t strcpy_s(char *dest,rsize_t dest_size,const char *src)
The invocation for your example should be:
#include char a[50] = "void"; char b[3]; strcpy_s(b, sizeof(b), a); printf("String = %s", b);