You can get a huge string from a tiny one S by repeating doing following replacement N times.
What's the substring containing M characters starting at the index K?
There are multiple test cases. Process to the End of File.
The first line of each test contains the string S made up of nonspacing graphic characters, whose length doesn't exceed 100. The second line contains three integers: 0 ≤ N ≤ 100, 1 ≤ M ≤ 200 and 0 ≤ K ≤ 10
81.
For each test case, output the substring
[K, min(length(S), K + M))