Under construction

Still being built. Things may change

Vera and ABCDE

Interview

Time limit2sMemory limit512 MB

Summary
Given a string of N letters from A to E, render the 5x3 pattern for each letter side by side and print the resulting 5 rows of 3N characters.
Level

Easy3 of 10

Topics
Implementation, String, Simulation, Array
Solved
No attempts yet

Problem

When Vera was learning English, she played with five kinds of toy blocks, one for each of the first five uppercase letters. One block is a 5×35 \times 3 grid of the characters . and *. The five kinds look like this.

*** *** *** *** ***
*.* *.* *.. *.* *..
*** *** *.. *.* ***
*.* *.* *.. *.* *..
*.* *** *** *** ***

Vera has a word SS of length NN. Lay the block for each letter of SS in a row from left to right, and report the shape that comes out.

Input

The first line contains an integer NN (1≤N≤20171 \le N \le 2017).

The second line contains a string SS of length NN. SS consists only of the letters A, B, C, D, E.

Output

Print the shape of the blocks laid in a row on five lines. Each line has 3N3N characters.

Examples2

  1. Example 1

    Input
    5
    ABCDE
    
    Expected output
    ***************
    *.**.**..*.**..
    *******..*.****
    *.**.**..*.**..
    *.*************
    
  2. Example 2

    Input
    10
    ECADBECADB
    
    Expected output
    ******************************
    *..*..*.**.**.**..*..*.**.**.*
    ****..****.********..****.****
    *..*..*.**.**.**..*..*.**.**.*
    *******.**************.*******