๋ฐ์ํ
๐ค๋ฌธ์ ํด๊ฒฐ
-
D3 | ?
๐จ ๊ท์น์ ์ฐพ๋ ๋ฌธ์
๐จ ์ฒซ์ค๊ณผ ๋ง์ง๋ง์ค์ ..#. ๊ณผ ๋์ .
๐จ ๋๋ฒ์งธ์ค๊ณผ ๋ค๋ฒ์งธ์ค์ .#.# ๊ณผ ๋์ .
๐จ ๊ฐ์ด๋ฐ ๋ฌธ์๊ฐ ๋ค์ด๊ฐ๋์ค์ #. + ๋ฌธ์ํ๋ + . ๊ณผ ๋ง์ง๋ง์ #
๐ป์์ค ์ฝ๋
for tc in range(int(input())):
word = input()
a = '..#.'
b = '.#.#'
ab_last = '.'
c1 = '#.'
c2 = '.'
c_last = '#'
N = len(word)
answer = ['']*5
answer[0] += a*N + ab_last
answer[1] += b*N + ab_last
for w in word:
answer[2] += c1 + w + c2
answer[2] += c_last
answer[3] += b*N + ab_last
answer[4] += a*N + ab_last
for rw in answer:
print(rw)
๐๋ฌธ์ ํ์ธ
์ถ์ฒ: SW Expert Academy
๋ฐ์ํ
'Algorithm Problem > Python' ์นดํ ๊ณ ๋ฆฌ์ ๋ค๋ฅธ ๊ธ
[python] SWEA - 4579. ์ธ์์ ๋ชจ๋ ํฐ๋ฆฐ๋๋กฌ 2 (0) | 2020.12.14 |
---|---|
[python] SWEA - 4698. ํ ๋ค์ค์ ํน๋ณํ ์์ (0) | 2020.12.13 |
[python] SWEA - 4789. ์ฑ๊ณต์ ์ธ ๊ณต์ฐ ๊ธฐํ (0) | 2020.12.11 |
[python] SWEA - 5688. ์ธ์ ๊ณฑ๊ทผ์ ์ฐพ์๋ผ (0) | 2020.12.10 |
[python] SWEA - 9700. USB ๊ฝ๊ธฐ์ ๋ฏธ์คํฐ๋ฆฌ (0) | 2020.12.09 |