Answers for "memcpy built in c++"

C
1

memcpy c++ usage

#include<cstring> // or string.h
int main(){
	char a[4],b[]={"hello"};
  	memcpy(a,b,strlen(b)*sizeof(char));//destination,source,size*sizeof(type)
  	
}
Posted by: Guest on April-13-2021

Code answers related to "C"

Browse Popular Code Answers by Language