Function prototype
void *memcpy(void *destin, void *source, unsigned n);
parameter
destin-- points to the target array used to store the copied content, the type is cast to a void * pointer.
source-- points to the data source to be copied, the type is cast to a void * pointer.
n--The number of bytes to be copied.
return value
This function returns a pointer to the target storage area destin.
Features
Copy n bytes from the beginning of the memory address pointed to by the source to the beginning of the memory address pointed to by the destination destin.
Required header files
C语言:#include<string.h>
C++:#include<cstring>
Source: Baidu Encyclopedia