[COCI2006-2007#1] Okviri

题意翻译

“彼得·潘框架”是一种装饰文字,每一个字母都是由一个菱形框架。一个彼得·潘框架看起来像这样 (x是字母,#是框架): ``` ..#.. .#.#. #.X.# .#.#. ..#.. ``` 然而,只是一个框架会有些沉闷,所以我们每遇到三个字母会把第三个字母用温迪框架把它框起来。温迪框架看起来像这样: ``` ..*.. .*.*. *.X.* .*.*. ..*.. ``` 当温迪和彼得·潘的框架重叠时,温迪框架覆盖在上面。 (见样例3和4) 输入格式: 一行包含至多15个英文字母的大写字母。 输出格式: 输出使用彼得·潘和温迪框架写成的5行文字。

题目描述

“Peter Pan frames” are a way of decorating text in which every character is framed by a diamond shaped frame, with frames of neigbhouring characters interleaving. A Peter Pan frame for one letter looks like this ('X' is the letter we are framing): ``` ..#.. .#.#. #.X.# .#.#. ..#.. ``` However, such a framing would be somewhat dull so we'll frame every third letter using a “Wendyframe”. A Wendy frame looks like this: ``` ..*.. .*.*. *.X.* .*.*. ..*.. ``` When a Wendy frame interleaves with a Peter Pan frame, the Wendy frame (being much nicer) is put on top. For an example of the interleaving check the sample cases.

输入输出格式

输入格式


The first and only line of input will contain at most 15 capital letters of the English alphabet.

输出格式


Output the word written using Peter Pan and Wendy frames on 5 lines.

输入输出样例

输入样例 #1

A

输出样例 #1

..#..
.#.#.
#.A.#
.#.#.
..#..

输入样例 #2

DOG

输出样例 #2

..#...#...*..
.#.#.#.#.*.*.
#.D.#.O.*.G.*
.#.#.#.#.*.*.
..#...#...*..

输入样例 #3

ABCD

输出样例 #3

..#...#...*...#..
.#.#.#.#.*.*.#.#.
#.A.#.B.*.C.*.D.#
.#.#.#.#.*.*.#.#.
..#...#...*...#..