[BOJ 15444] Vera and ABCDE

View as PDF

Submit solution

Points: 1
Time limit: 2.0s
Memory limit: 512M

Problem types
Allowed languages
Assembly, Awk, C, C++, Java, Pascal, Perl, Python, Sed, Text

When Vera was learning English, she had 5 types of toy blocks, one for each of the first 5 uppercase letters. A block can be represented as a 5 × 3 grid with characters . and *. The 5 types of blocks look like the following:</p>

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

Vera has a word S with N letters and wonders what the corresponding sequence of blocks look like when arranged in a row.

입력 형식

Line 1 contains integer N (1 ≤ N ≤ 2017).</p>

Line 2 contains string S of length N, and consists of only letters A, B, C, D, E.

출력 형식

Print 5 lines, each with 3N characters, the corresponding sequence of blocks.

예제 입력 1

5
ABCDE

예제 출력 1

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

예제 입력 2

10
ECADBECADB

예제 출력 2

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

Comments

There are no comments at the moment.