Answers for "memcpy cpp"

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

Browse Popular Code Answers by Language