Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CPP

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)
  	
}
 
PREVIOUS NEXT
Tagged: #memcpy #usage
ADD COMMENT
Topic
Name
6+9 =