Shelf Shuffle
A long wooden shelf holds books arranged neatly from leftmost position to rightmost position , each book bearing a unique label equal to its initial position. The labels increase from left to right in natural order.
One day, a curious librarian accidentally removed the block of books from positions through (inclusive) and placed them back in reverse order. No other part of the shelf was disturbed during this single flipping operation.
Your task is to determine the new arrangement of labels on the shelf after this reversal. Given the values of , , and , output the sequence of labels from left to right once the specified segment has been flipped.
Input
Three integers , , and , where:
- is the total number of books on the shelf,
- and specify the starting and ending positions of the flipped segment.
Output
Print integers—the labels of the books on the shelf from leftmost to rightmost after performing the reversal between positions and .