| Ural Championship 2017 |
|---|
| Finished |
In this problem, your task is to construct a polygon with obstacles for a robot. The robot must enter the polygon through one of its corners, collide with obstacles exactly $$$k$$$ times, and then exit.
The robot is programmed with exactly $$$k$$$ commands, which instruct it to either turn left or turn right. The robot can only move forward, and upon each collision, it executes the next command in its program, turning left or right as specified.
The polygon must represent a rectangular grid where both the robot and an obstacle occupy single cells, and the robot can only move in directions parallel to the grid's edges. The robot collides with an obstacle if it is in a neighboring cell in the direction of the robot's movement.
The first line contains a single string $$$s$$$ ($$$1 \leq |s| \leq 50$$$) — the robot's program, consisting solely of the characters "L" and "R", which represent left and right turns, respectively.
Choose the dimensions of the polygon, $$$n$$$ ($$$1 \leq n \leq 50$$$) and $$$m$$$ ($$$1 \leq m \leq 50$$$), and output $$$n$$$ lines containing $$$m$$$ characters: "@", ".", and "#", which represent the following:
L
@#
LLLLLL
###### .....# ####.# #....# ###.## ###.## @...##
RLLRRLLRRLLRRLLRRLLRRLLL
@## ..# ###
LRRLLLLRRRLRRRRR
.......#... ...#......# .#......#.. ......#.... ..#........ .......#... .........#. @.#..#.....
| Name |
|---|


