C/Memory/Memory Move
Copy bytes to buffer from buffer: how to use memmove
#include <stdio.h>
#include <string.h>
int main ()
{
char str[] = "This is a line.....";
memmove (str + 20, str + 15,11);
puts (str);
return 0;
}
Memory move
#include <stdio.h>
#include <string.h>
#define SIZE 80
int main(void)
{
char str[SIZE], *p;
strcpy(str, "Hiiiiiiiiiiiiiiiii...");
p = str + 10;
memmove(str, p, SIZE);
printf("result after shift: %s", str);
return 0;
}