408417: GYM103115 K chino with c language
Description
In C language, there are two functions for copying arrays, $$$ memcpy $$$ and $$$memmove$$$. These two C language functions have a same purpose is copying the contents of a certain section of memory to a section of memory in units of bytes.
The difference between these two functions is that $$$ memcpy $$$ does not check whether the source address range and the destination address range in memory have overlapping parts. It follows the logic of copying each byte sequentially from left to right, so that can cause the data copied is not equal to original data.
When using the $$$memmove$$$ function, if the source address range and the destination address range have overlapping part, $$$memmove$$$ will do special processing to ensure that the memory of the destination address range is filled with original data.
Now suppose that both the $$$memcpy$$$ and $$$memmove$$$ function calls require three parameters, $$$p_1, p_2, l$$$, which respectively represent the source address, destination address, and the number of bytes copied. For example, given a string "abcdefg", if you call $$$memcopy(1,3,5)$$$, the result will be "abababa", if you call $$$memmove(1,3,5)$$$, the result will be It is "ababcde".
Now give you a string S, and three call parameters, $$$p_1, p_2, l$$$. Please tell Chino what the calling results of $$$memcopy$$$ and $$$memmove$$$ respectively are.
InputThe first line of input data contains only a positive integer $$$n(1 \leq n \leq 10^5)$$$ indicates the length of the string.
The second line of input data contain a string S of length n. S includes only lowercase English letters.
The third line of input data contain three integers $$$p_1,p_2,l(1 \leq p_1,p_2,l \leq n)$$$
And guarantee $$$1 \leq p_1+l-1,p_2+l-1 \leq n$$$ represents the parameters of calling two functions .
OutputPlease output two lines, the first line represents the result of calling the $$$memcopy$$$ function, the second line represents the result of calling $$$memmove$$$.
ExampleInput7 abcdefg 1 3 5Output
abababa ababcde