4485: A. Lily

内存限制:512 MB 时间限制:1 S 标准输入输出
题目类型:传统 评测方式:Special Judge 上传者:
提交:21 通过:12

题目描述

- They serve the purpose of changing hydrogen into breathable oxygen, and they're as necessary here, as the air is on earth.
- But I still say, they're flowers.
- If you like.
- Do you sell them?
- I'm afraid not.
- But, maybe we can make a deal.
- What do you mean?
- Oh you see, you don't have to send them anywhere. I'll pay for them. But then, I'll leave them here, for you.
— Assignment Outerspace1960
Everything that has a beginning has an ending. My journey has been reaching its ending, and I've been ready to say goodbye to my yesterday. But you, my dear friend, your journey is still thriving here at the 2022 CCPC Guilin Site. We sincerely hope you find a brand new milestone here, and forge ahead in the future with your love and passion.
Lily means a kind of beautiful flower. She usually only blooms once a year, so it could be very precious if you see a lily blooming. However, she is highly toxic to cats, so you must be aware of keeping curious cats away from lovely lilies.
You have n grids of soil land in a row, for 1 to n, some with lilies blooming. We don't want to hurt lilies, as well as cats. You can put some cat food on the grids, but for any grid i with cat food, grids with indices falling in the range [i - 1, i + 1] must not contain lily flowers. You love cats and lilies, so you want to maximize the number of grids having cat food.
Design a plan to fulfill the above requirements.

输入格式

There's a single integer n (1 <= n <= 1000) in the first line, denoting the number of grids.
The second line contains a string R consisting of only 'L' and '.', denoting the grids with and without lilies.

输出格式

The output contains a single line with string R' consisting of only 'L', '.' and 'C', where 'C' means the cat food you assigned to the empty grids in R while fulfilling the above requirements.
If there are multiple solutions, print any.

输入样例 复制

5
..L..

输出样例 复制

C.L.C

数据范围与提示

input
2
..

output

CC