#3579. A Reverse

0

A Reverse

A Reverse

题目描述

You are given integers LL, RR, and a string SS consisting of lowercase English letters.
Print this string after reversing (the order of) the LL-th through RR-th characters.

输入格式

Input is given from Standard Input in the following format: LL RR SS

输出格式

Print the specified string.

3 7
abcdefgh
abgfedch
1 7
reviver
reviver
4 13
merrychristmas
meramtsirhcyrs

提示

SS consists of lowercase English letters. 1≤∣S∣≤1051 \le |S| \le 10^5 (∣S∣|S| is the length of SS.) LL and RR are integers. 1≤L≤R≤∣S∣1 \le L \le R \le |S|After reversing the 33-rd through 77-th characters of abcdefghabcdefgh, we have abgfedchabgfedch.
The operation may result in the same string as the original.

标签: AtCoder|abc233B

来源

AtCoder|abc233B