memcpy() function in C with Example
memcpy() is a library function, which is declared in the “string.h” header file - it is used to copy a block of memory from one location to another (it can also be considered as to copy a string to another).
Syntax of memcpy():
memcpy(void*str1, const void* str2, size_t n);
It copies n bytes of str2 to str1.