Problem:


Score : 200 points

Problem Statement

There is an image with a height of H pixels and a width of W pixels. Each of the pixels is represented by either . or *. The character representing the pixel at the i-th row from the top and the j-th column from the left, is denoted by C_{i,j}.

Extend this image vertically so that its height is doubled. That is, print a image with a height of 2H pixels and a width of W pixels where the pixel at the i-th row and j-th column is equal to C_{(i+1)/2,j} (the result of division is rounded down).

Constraints

1≦H, W≦100

C_{i,j} is either . or *.

Input

The input is given from Standard Input in the following format:

H W
C_{1,1}...C_{1,W}
:
C_{H,1}...C_{H,W}

Output

Print the extended image.

Sample Input 1

2 2
*.
.*

Sample Output 1

*.
*.
.*
.*

Sample Input 2

1 4
***.

Sample Output 2

***.
***.

Sample Input 3

9 20
.....***....***.....
....*...*..*...*....
...*.....**.....*...
...*.....*......*...
....*.....*....*....
.....**..*...**.....
.......*..*.*.......
........**.*........
.........**.........

Sample Output 3

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



Sample input:
2 2
*.
.*


Sample output:
*.
*.
.*
.*

Submission status: Accepted

Solution code:
H,W = map(int,input().split())

output = []
for _ in range(H):
  s = input()
  output.append(s)
  output.append(s)

print(*output,sep='\n')

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
c = [str(input()) for x in range(h)]
for i in c:
    for j in range(2):
        print(i)

Submission status: Accepted

Solution code:
H,W = map(int, input().split())
c = [list(map(str, input().split())) for _ in range(H)]
for i in c:
    print(i[0])
    print(i[0])

Submission status: Accepted

Solution code:
h,w = map(int, input().split())
for i in range(h):
    s = input()
    print(s)
    print(s)

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
S=[]
for _ in range(a):
    S.append(input())
for i in S:
    print(i)
    print(i)

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
A = [input() for _ in range(H)]
for i in range(H):
    print(A[i])
    print(A[i])

Submission status: Accepted

Solution code:
a = []
for i in range(int(input().split()[0])):
    a.append(input())
for i in a:
    print(i)
    print(i)

Submission status: Accepted

Solution code:
H , W = map(int,input().split())
C = [input() for i in range(H)]
for i in range(H):
	print(C[i])
	print(C[i])

Submission status: Accepted

Solution code:
h,w=map(int,input().split())
for i in range(h):
    s=input()
    print(s+"\n"+s)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# -*- coding: utf-8 -*-


def main():
    H, W = map(int, input().split())
    for _ in range(H):
        C = input()
        print(C + '\n' + C)


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
#!/usr/bin/env python3

h,w=map(int,input().split())
s=[]
for i in range(h):
    a=input()
    s.append(a)
    s.append(a)

print("\n".join(s))

Submission status: Accepted

Solution code:
from itertools import chain

H, W = [int(n) for n in input().split()]

def main():
    c = [input() for _ in range(H)]
    c2 = list(chain.from_iterable(zip(c, c)))
    print('\n'.join(c2))

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
for id in range(h):
    str = input()
    print(str)
    print(str)

Submission status: Accepted

Solution code:
n,l=map(int,input().split())
a = [input() for i in range(n)]
r=[]
for x in a:
    r.append(x)
    r.append(x)
for x in r:
    print("".join(x))

Submission status: Accepted

Solution code:
h,w = map(int,input().split())

for i in range(h):
  s = input()
  print(s)
  print(s)

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
c = []
for i in range(h):
    c.append(input())

for i in range(h):
    print(c[i])
    print(c[i])

Submission status: Accepted

Solution code:
H, W = map(int, input().split())

C = [input() for i in range(H)]

for s in C:
    print(s)
    print(s)

Submission status: Accepted

Solution code:
"""
author : halo2halo
date : 2, Feb, 2020
"""

import sys

# import itertools
# import numpy as np

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(10 ** 7)

mod = 10 ** 9 + 7

H,W = map(int, readline().split())
S=read().decode('Utf8').split()
for i in S:
    print(i)
    print(i)

Submission status: Accepted

Solution code:
H, W = map(int, input().split())

moji = []
for _ in range(H):
    moji.append(input())

for m in moji:
    print(m)
    print(m)

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
c = [input() for _ in range(h)]

for i in range(h):
    print(c[i])
    print(c[i])

Submission status: Accepted

Solution code:
H,W = [int(i) for i in input().split()]

for i in range(H):
    s = input()
    print(str(s))
    print(str(s))

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
for _ in range(H):
    L = input()
    print(L)
    print(L)

Submission status: Accepted

Solution code:
h, w = map(int, input().split())

l = []

for i in range(h):
  s = input()
  l.append(s)
  

for i in range(h):
  print(l[i])
  print(l[i])

Submission status: Accepted

Solution code:
h,w=map(int,input().split())
for _ in range(h):
  a=input()
  print(a)
  print(a)

Submission status: Accepted

Solution code:
h,w=map(int,input().split())
for i in range(h):
    a=input()
    for i in range(2):
        print(a)

Submission status: Accepted

Solution code:
def main():
    h, w = map(int, input().split())

    for _ in range(h):
        str_list = list(input().split())
        print(*str_list)
        print(*str_list)

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
h,w = map(int, input().split())
c = [list(input()) for i in range(h)]
a=[[] for i in range(h*2)]

for i in range(h*2):
    a[i]=c[i//2]

for i in range(h*2):
    print(''.join(a[i]))

Submission status: Accepted

Solution code:
def solve(h, w, C):
    for line in C:
        print('{0}\n{0}'.format(line))

_h, _w = map(int, input().split())
_C = [input() for _ in range(_h)]
solve(_h, _w, _C)

Submission status: Accepted

Solution code:
h,w=map(int,input().split())
for i in range(h):
 s=input()
 print(s+'\n'+s)

Submission status: Accepted

Solution code:
h,w = map(int,input().split())
pixcels = []

for i in range(h):
    pixcels.append(input())
    
output=[]

for i in range(h):
    output.append(pixcels[i])
    output.append(pixcels[i])

for i in range(2*h):
    print(output[i])

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
graph = [input() for _ in range(H)]
for line in graph:
    for i in range(2):
        print(line)

Submission status: Accepted

Solution code:
H,W = [int(i) for i in input().split()]
for i in range(H):
    mank = input()
    print(mank)
    print(mank)

Submission status: Accepted

Solution code:
H,W=map(int,input().split())
L=[[j for j in input()] for i in range(H)]
J=L
for i in range(H):
    print("".join(L[i]))
    print("".join(J[i]))

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
for i in range(h):
	x = input()
	print (x)
	print (x)

Submission status: Accepted

Solution code:
h,w = map(int,input().split())
c = list(input() for _ in range(h))

for i in c:
    print(i)
    print(i)

Submission status: Accepted

Solution code:
H, W = tuple(map(int, input().split()))

lines = []
for _ in range(H):
    line = input()
    lines.append(line)
    lines.append(line)
print('\n'.join(lines))

Submission status: Accepted

Solution code:
h,w = map(int,input().split())
c =  [list(input()) for hoge in range(h)]
for i in range(h):
         print(''.join(c[i]))
         print(''.join(c[i]))

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
p = [input() for i in range(h)]
for i in p:
    for n in range(2):
        print(i)

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
p = [input() for i in range(h)]

for i in p:
    for n in range(2):
        print(i)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys
INF = float("inf")


def main():
    H, W = map(int, input().split())
    C = [input() for _ in range(H)]
    for i in range(2*H):
        buf = []
        for j in range(W):
            buf.append(C[i//2][j])
        print("".join(buf))


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
List = []
for i in range(H):
    List.append(input())
for i in range(len(List)):
    print(List[i])
    print(List[i])

Submission status: Accepted

Solution code:
arr = input().split()
h = int(arr[0])
w = int(arr[1])


c = [['-'] * w for i in range(h)]

for i in range(h):
    arr = input()
    arr = list(arr)
    c[i] = arr

x = [['-'] * w for i in range(2*h)]

for i in range(h):
    x[i*2] = c[i]
    x[i*2+1] = c[i]

for i in range(2*h):
    for j in range(w):
        print(x[i][j],end='')
    print('')

Submission status: Accepted

Solution code:
h, w = map(int, input().split())

for _ in range(h):
  p_row = input()
  print(p_row)
  print(p_row)

Submission status: Accepted

Solution code:
H, W = map(int, input().split())

for i in range(H):
    C = input()
    print(C)
    print(C)

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
s = [input() for _ in range(h)]

for i in s:
    print(i)
    print(i)

Submission status: Accepted

Solution code:
h,w=map(int,input().split())
for _ in range(h):
  s=input()
  print(s)
  print(s)

Submission status: Accepted

Solution code:
h,w = map(int,input().split())
for i in range(h):
  s = input()
  for i in range(2):
    print(s)

Submission status: Accepted

Solution code:
a = input().split()
h = int(a[0])
w = int(a[1])

b = []
c =[]

for i in range(h):
    s = input()
    b.append(s)

for i in range(h):
    c.append(b[i])
    c.append(b[i])

for i in range(len(c)):
    print(c[i])

Submission status: Accepted

Solution code:
#python3

def main():
    h, w = map(int, input().split())
    strings = [input() for _ in range(h)]
    for i in strings:
        print(i)
        print(i)
main()

Submission status: Accepted

Solution code:
h,w=map(int,input().split())
c=[input() for i in range(h)]
for i in c:
    print(i)
    print(i)

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
*c, = [input().strip() for _ in range(H)]
for v in c:
    print(v)
    print(v)

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
tmp = [input() for _ in range(H)]

for i in range(H):
    print(tmp[i])
    print(tmp[i])

Submission status: Accepted

Solution code:
h, w = map(int, input().split())

for _ in range(h):
	s = input()
	print(s)
	print(s)

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
c = [input() for _ in range(H)]

for i in c:
  print(i)
  print(i)

Submission status: Accepted

Solution code:
INT = lambda: int(input())
INTM = lambda: map(int,input().split())
STRM = lambda: map(str,input().split())
STR = lambda: str(input())
LIST = lambda: list(map(int,input().split()))
LISTS = lambda: list(map(str,input().split()))
def do():
    ans=[]
    h,w=INTM()
    for i in range(h):
        temp=STR()
        ans.append(temp)
        ans.append(temp)
    for i in range(2*h):
        print(*ans[i],sep='')
if __name__ == '__main__':
    do()

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
cl = list(input() for _ in range(h))

for c in cl:
    print('{}\n{}'.format(c, c))

Submission status: Accepted

Solution code:
h,w=map(int,input().split())

for _ in range(h):
  l=input()
  print(l)
  print(l)

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
C = [None] * H
for y in range(H):
    C[y] = input()

for y in range(H * 2):
    print(C[y // 2])

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
h,w=map(int,input().split())
for i in range(h):
    c=input().strip()
    print(c)
    print(c)

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
H, W = [int(x) for x in input().split()]
C = []
for _ in range(H):
    C.append(input().rstrip())
for i in C:
    for _ in range(2):
        print(i)

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
C = []
for i in range(h):
    C.append(input())

for i in range(h):
    print(C[i])
    print(C[i])

Submission status: Accepted

Solution code:
#!/usr/bin/env python3

h,w = map(int,input().split())
c = [list(input()) if i % 2 == 0 else [] for i in range(2*h)]

for i in range(h):
    c[2*i+1] = c[2*i]
for i in range(2*h):
    print(''.join(c[i]))

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

h, w = map(int, input().split())
c = []
for i in range(h):
    c.append(input())

for i in range(h):
    print(c[i])
    print(c[i])

Submission status: Accepted

Solution code:
h,w = map(int,input().split())

pixels = []

for i in range(h):
  pixels.append(input())

for pixel in pixels:
  print(pixel)
  print(pixel)

Submission status: Accepted

Solution code:
h,w=map(int,input().split())
a=[]
for i in range(h):
   a.append(input().split())

for i in range(h):
   print(" ".join(a[i]))
   print(" ".join(a[i]))

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
board = []
for i in range(h):
    board.append(input())

for l in board:
    print(l)
    print(l)

Submission status: Accepted

Solution code:
H, W = map(int, input().split())

image = []

for _ in range(H):
  image.append(input())

for i in range(H):
	print(image[i])
	print(image[i])

Submission status: Accepted

Solution code:
h,w = map(int,input().split())
c = [list(map(str,input().split())) for _ in range(h)]

for i in range(h):
    print(''.join(c[i]))
    print(''.join(c[i]))

Submission status: Accepted

Solution code:
# スペース区切りの整数の入力
H,W = map(int, input().split())

for i in range(H):
  input_string = str(input())
  print(input_string)
  print(input_string)

Submission status: Accepted

Solution code:

a = input().split(" ")[0]
for a in range(int(a)):
  b = input()
  print(b)
  print(b)

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
pic = [[input()] for _ in range(h)]

for p in pic:
    print("".join(p))
    print("".join(p))

Submission status: Accepted

Solution code:
h,w = map(int, input().split())
for _ in range(h):
    s = input()
    print(s)
    print(s)

Submission status: Accepted

Solution code:
h,w = map(int, input().split())
l=[]
for i in range(h):
    l.append(list(input().split())*2)

for i in range(h):
    for j in range(2):
        print(l[i][j])

Submission status: Accepted

Solution code:
H,W=map(int,input().split())
A=[input() for i in range(H)]

for i in range(H):
    print(A[i])
    print(A[i])

Submission status: Accepted

Solution code:
H,W=map(int,input().split())
A=[]
for i in range(H):
    A.append(input())

for i in range(H):
    print(A[i])
    print(A[i])

Submission status: Accepted

Solution code:
h,w=map(int,input().split())
L=[list(input()) for _ in range(h)]
for l in L:
    print(*l,sep='')
    print(*l,sep='')

Submission status: Accepted

Solution code:
data_num = [int(i) for i in input().split(" ")]
data = [input() for i in range(data_num[0])]
for i in data:
  print(i)
  print(i)

Submission status: Accepted

Solution code:
h,w=map(int,input().split())
for i in range(h):
    s=input()
    print(s)
    print(s)

Submission status: Accepted

Solution code:
H,W = map(int,input().split())
for i in range(H):
  c = str(input())
  print(c)
  print(c)

Submission status: Accepted

Solution code:
H,W = map(int, input().split())

C = []

for _ in range(H):
    l = list(input())
    C.append(l)
D = []
for i in range(2*H):
    l = []
    for j in range(W):
        l.append(C[i//2][j])

    D.append(l)

for i in range(len(D)):
    print(*D[i],sep="")

Submission status: Accepted

Solution code:
h, w = map(int, input().split())

c = []
for i in range(h):
   tmp = [x for x in input()]
   c.append(tmp)

for i in range(h):
   tmp = [print(x, end='') for x in c[i]]
   print()
   tmp = [print(x, end='') for x in c[i]]
   print()

Submission status: Accepted

Solution code:
hw=list(map(int,input().split()))
image=[]
for i in range(hw[0]):
    image.append(input())
for i in range(hw[0]):
    print(image[i])
    print(image[i])

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
 
import math
import itertools
import sys
import copy
 
# 入力
H, W = map(int, input().split())
#A = str(input())
c = []
for _ in range(H) :
  c.append(str(input()))
#print (c)

for i in range(H) :
  for _ in range(2) :
    print (c[i])

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
grid = [list(input().split()) for _ in range(H)]
for i in range(H):
  print(*grid[i])
  print(*grid[i])

Submission status: Accepted

Solution code:
H , W = map(int, input().split())
Clist = [input().split() for i in range(H)]

for a in range(H):
    print(*Clist[a])
    print(*Clist[a])

Submission status: Accepted

Solution code:
h,w = map(int,input().split())

for _ in range(h):
   a = input()
   print(a)
   print(a)

Submission status: Accepted

Solution code:
h,w=[int(x) for x in input().rstrip().split()]
ans=[]
for i in range(h):
    moji=input()
    ans.append(moji)

for i in range(h):
    print(ans[i])
    print(ans[i])

Submission status: Accepted

Solution code:
H, W = map(int,input().split())
for _ in range(H):
    C = input()
    print(C)
    print(C)

Submission status: Accepted

Solution code:
h,w = map(int,input().split())
s = [input() for _ in range(h)]
ans=[]
for i in range(h):
    ans.append(s[i])
    ans.append(s[i])
for i in range(h*2):
    print(ans[i])

Submission status: Accepted

Solution code:
a,b= map(int, input().split())
l=[input().split() for i in range(a)]

for i in range(a):
  print(" ".join(l[i]))
  print(" ".join(l[i]))

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
ans = ""
for i in range(h):
  l = input()
  ans += l+"\r\n"+l+"\r\n"
print(ans)

Submission status: Accepted

Solution code:
import sys
h,w = map(int, input().split())

c = [input() for _ in range(h)]
for i in range(h):
    print(c[i])
    print(c[i])

Submission status: Accepted

Solution code:

h,w = map(int,input().split())

s = [input() for i in range(h)]
#print(s)

for i in range(h):
    print(s[i])
    print(s[i])

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
c = [input() for _ in range(h)]
ans = []
for i in range(h):
    ans.append(c[i])
    ans.append(c[i])
for i in range(2 * h):
    print(*ans[i], sep='')

Submission status: Accepted

Solution code:
[print("{}\n{}".format(i, i)) for i in [input() for _ in range(list(map(int, input().split())).pop(0))]]

Submission status: Accepted

Solution code:
H, _ = map(int, input().split())
C = [input() for i in range(H)]
for i in C:
    print("{}\n{}".format(i, i))

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys, math, itertools, collections, bisect
input = lambda: sys.stdin.buffer.readline().rstrip().decode('utf-8')
inf = float('inf')
ans = 0 ;count = 0 ;pro = 1

h,w=map(int,input().split())
data=[""]*(2*h)
for i in range(0,2*h,2):
    data[i]=input()
for i in range(0,2*h,2):
    data[i+1]=data[i]
print(*data,sep="\n")

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
C = [''] * H
for i in range(H):
    C[i] = input()
    print(C[i])
    print(C[i])

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
C = [''] * H
for i in range(H):
    C[i] = input()

for i in range(H):
    print(C[i])
    print(C[i])

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
import sys
import itertools#これは色々使える組み込み関数みたいなやつ
import math#数学的計算はこれでいける。普通に0.5乗しても計算可能
#w=input()
H, W=input().split()
H=int(H)
W=int(W)
#C=int(C)
#K=int(K)
i=0
ID_list=[]
ID_sublist=[]
pixel_list=[]
H_dummy=0
W_dummy=0
C_dummy=0
#センテンスを暗記するのではなく、まずinput()を書いて、膨らます感じで記述する。すると#思考の流れ通りに書ける。素晴らしい！
#for i in range(K):
# ID_list.append(i+1)
#print(ID_list)
#for i in range(H)
#この下の行が二次元リストの読み込
#intを消して記号を読み込めるようにしたしかしこれでは文字列から読み込んでいるのと同じ
pixel_list =  [list(input())for i in range(H)]
#for i in range(H):
#  ppixel_list=list(input())
#  
#print(pixel_list)
i=0
j=0
high_pixel_list =[['' for i in range(W)]for j in range(2*H)]
#print(high_pixel_list)
#print(pixel_list[0][1])#行　列の順番にかっこが並んでいる
j=0
k=0
for j in range(2*H):
    for k in range(W):
        #print(j, k)
        high_pixel_list[j][k]=pixel_list[j//2][k]
    print(''.join(high_pixel_list[j][:]))
#print(high_pixel_list)

 



#センテンスを暗記するのではなく、まずinput()を書いて、膨らます感じで記述する。すると#思考の流れ通りに書ける。素晴らしい！

#x=[]
#y=[]
#t, x, y = [0]*(H+1), [0]*(H+1), [0]*(H+1)#H+1個の空のリストを作成(原点を入れて##るから一つ増える)
#delta_t=0
#delta_x=0
#delta_y=0
#l=0
#t[0],x[0],y[0]=[0, 0, 0]
#とりあえず入力までは完成した．
#for i in range(Hyy):
# t[i+1], x[i+1], y[i+1] = map(int, input().split())
#child_i =  list(map(int, input().split()))
#w_len=len(w)
#w_list=list(w)
#print(len(w_list))
#print(w_list)
#child_il=sorted(child_i)
#print(child_il)#リストの右端のほうが大きい

Submission status: Accepted

Solution code:
h, w = [int(x) for x in input().split()]
for _ in range(h):
	s = input()
	print(s)
	print(s)

Submission status: Accepted

Solution code:
ans=[]
h,w=map(int,input().split())
for i in range(h):
  l=list(input())
  ans.append(l)
  ans.append(l)
for i in range(2*h):
  print(*ans[i],sep='')

Submission status: Accepted

Solution code:
import sys

h, w, = map(int, sys.stdin.readline().split())
canvas = sys.stdin.read().split()

def main():
    for i in range(h):
        for _ in range(2):
            yield canvas[i]

if __name__ == '__main__':
    ans = main()
    print(*ans, sep='\n')

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
c = [list(input()) for _ in range(h)]

for i in range(2 * h):
    tmp = ''
    for j in range(w):
        tmp += c[i // 2][j]
    print(tmp)

Submission status: Accepted

Solution code:
H, W = map(int, input().split(' '))
c = []
for i in range(H):
    c.append(input())
for r in c:
    print(r)
    print(r)

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
ls_c = [input() for _ in range(h)]

for i in range(h):
    print(ls_c[i])
    print(ls_c[i])

Submission status: Accepted

Solution code:
H, W = map(int, input().split())

# 絵を入力
C = [input() for _ in range(H)]
 
# 2回出力
for i in range(H):
    for j in range(2):
        print(C[i])

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
c = [input() for i in range(h)]
a = []
for i in range(h):
    a.append(c[i])
    a.append(c[i])
print(*a, sep="\n")

Submission status: Accepted

Solution code:
h,w=input().split()
h,w=int(h),int(w)
k=1
li=[]
while k<=h:
    a=input().rstrip()
    li.append(a)
    k+=1
k=0
while k<h:
    print(li[k])
    print(li[k])
    k+=1

Submission status: Accepted

Solution code:
#49B
h,w=map(int,input().split())
l=[list(input()) for i in range(h)]
n=2*h
ans=[]
for i in range(1,1+n):
    ans=l[((i+1)//2)-1]
    print(*ans,sep='')

Submission status: Accepted

Solution code:
h,w = map(int,input().split())
image = [input() for _ in range(h)]
for i in range(h):
  print(image[i])
  print(image[i])

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
c = ['']
for j in range(h):
    c_in = input()
    c.append(c_in)

for i in range(1, 2*h + 1):
    print(c[ (i + 1)//2 ])

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
ret = ""
for _ in range(H):
    s = input()
    ret += s + "\n" + s + "\n"
print(ret)

Submission status: Accepted

Solution code:
h,w=map(int,input().split())
c=[input() for _ in range(h)]
for i in range(h):
    print(c[i])
    print(c[i])

Submission status: Accepted

Solution code:
H, W = map(int, input().split())

for i in range(H):
    row = input()
    print(row)
    print(row)

Submission status: Accepted

Solution code:
h, w = map(int, input().split())

for i in range(h):
    c = list(input())
    x = []
    for j in range(w):
        x.append(c[j])
    ans = ''.join(x)
    print(ans)
    print(ans)

Submission status: Accepted

Solution code:
HW = list(map(int,input().split()))
H=HW[0]
W=HW[1]
C = [input() for i in range(H)]
tmp=[]

for c in C:
    tmp.append(c)
    tmp.append(c)

print('\n'.join(tmp))

Submission status: Accepted

Solution code:
h,w = map(int, input().split())

lis =[]

for i in range(h):
    lis.append(input())


for a in lis:
    print(a)
    print(a)

Submission status: Accepted

Solution code:
img_ls = []
H, W = map(int,input().split()) 

for i in range(H):
    img_ls.append(input())

for line in img_ls:
    print(line)
    print(line)

Submission status: Accepted

Solution code:
import sys
from functools import reduce
import copy
import math
from pprint import pprint
import collections
import bisect
import itertools


sys.setrecursionlimit(4100000)


def inputs(num_of_input):
    ins = [input() for i in range(num_of_input)]
    return ins


def int_inputs(num_of_input):
    ins = [int(input()) for i in range(num_of_input)]
    return ins


def solve(inputs):
    pict = inputs
    new_pict = []

    for row in pict:
        new_pict.append(row)
        new_pict.append(row)
    return new_pict


def string_to_int(string):
    return list(map(lambda x: int(x), string.split()))


if __name__ == "__main__":
    [N, M] = string_to_int(input())
    ret = solve(inputs(N))
    for r in ret:
        print(r)

Submission status: Accepted

Solution code:
H , W = map(int,input().split())
for i in range(H):
    l = input()
    print(l)
    print(l)

Submission status: Accepted

Solution code:
#n = int(input())
#n,k = map(int,input().split())
#x = list(map(int,input().split()))

h,w = map(int,input().split())

for i in range(h):
    a = input()
    print(a)
    print(a)

Submission status: Accepted

Solution code:
H,W = map(int, input().split())
C = [input() for _ in range(H)]

for i in range(H):
    for j in range(2):
        print(C[i])

Submission status: Accepted

Solution code:
dbflag=""

def debug(*args):
	if ""!=dbflag: print(*args)

if ""!=dbflag: _INDATA=open(dbflag)

def readline():
	if ""!=dbflag:return _INDATA.readline()
	else: return input()


result = -1


H, W = map(int, readline().split())

import numpy as np
data=np.ndarray(shape=(H,W),dtype=object)
for i in range(0,H):
	data[i,:]=list(readline().rstrip())
	
for i in range(0,2*H):
	for j in range(0,W):
		#debug(i,j,(i)//2)
		print(data[(i)//2, j],end="")
	
	print("")

Submission status: Accepted

Solution code:
h, w = map(int, input().split())

image = []
for i in range(h):
    line = list(input())
    image.append(line)

for i in range(h):
    for j in range(2):
        for j in range(w):
            print(image[i][j], end='')
        print()

Submission status: Accepted

Solution code:




if __name__ == '__main__':
    H,W=list(map(int,input().split()))
    C=[["" for i in range(W)] for j in range(H)]
    for i in range(H):
        temp=input()
        for j in range(W):
            C[i][j]=temp[j]

    ans=[["" for i in range(W)] for j in range(2*H)]
    for i in range(0,2*H,2):
        for j in range(W):
            ans[i][j]=C[i//2][j]
            ans[i+1][j]=C[i//2][j]




    for i in range(2*H):
        print(''.join(ans[i]))

Submission status: Accepted

Solution code:
tate, yoko = map(int, input().split(" "))

for _ in range(tate):
    line = input()
    print(line + '\n' + line)

Submission status: Accepted

Solution code:
h, _ = [int(i) for i in input().split()]
lst = [input() for _ in range(h)]
for i in lst:
  print(i)
  print(i)

Submission status: Accepted

Solution code:
h, _ = [int(i) for i in input().split()]
for i in range(h):
  a = input()
  print(a)
  print(a)

Submission status: Accepted

Solution code:
h,w = map(int,input().split())
for i in range(h):
    a = input()
    print(a)
    print(a)

Submission status: Accepted

Solution code:
h, w = map(int, input().split())

for i in range(h):
    l = input()
    print(l)
    print(l)

Submission status: Accepted

Solution code:
h,w=map(int,input().split())
for i in range(h):
	a=input()
	print(a)
	print(a)

Submission status: Accepted

Solution code:
h,w = map(int,input().split())

#n回の入力をリストに入れる
l=[str(input()) for i in range(h)]

for i in range(h):
	print(l[i])
	print(l[i])

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
C = []
for i in range(H):
    C.append(input())
for i in range(H):
    print(C[i])
    print(C[i])

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
C = [input() for _ in range(H)]

for c in C:
    print(c)
    print(c)

Submission status: Accepted

Solution code:
h,w=map(int,input().split())
for i in range(h):
  x=input()
  print(x)
  print(x)

Submission status: Accepted

Solution code:
from sys import stdin

h,w = [int(x) for x in stdin.readline().rstrip().split()]
li = [["" for i in range(w)]for j in range(h)]
for i in range(h):
    s = stdin.readline().rstrip()
    for j in range(w):
        li[i][j] = s[j]

lin = []

for i in li:
    lin.append(i)
    lin.append(i)

for i in lin:
    print("".join(i))

Submission status: Accepted

Solution code:
# B - たてなが / Thin
h,w = map(int,input().split())

c = [input() for i in range(h)]
ans = []
for i in range(2*h):
    ans.append(c[i//2])

print(*ans,sep='\n')

Submission status: Accepted

Solution code:
h,w = map(int,input().split())

ans_list = []

for i in range(h):
    append = str(input())
    
    ans_list.append(append)
    ans_list.append(append)
    

for j in range(len(ans_list)):
    
    print(ans_list[j])

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
c = [input() for _ in range(h)]

for i in range(h):
	print (c[i])
	print (c[i])

Submission status: Accepted

Solution code:
H, W = map(int, input().split())

ans_list = []
i = 0

while i < H:
    input_list = input()
    ans_list.append(input_list)
    ans_list.append(input_list)
    i += 1

for _ in ans_list:
    print(_)

Submission status: Accepted

Solution code:
[h,w]=list(map(int,input().split()))
pic=[]
for i in range(h):
	pic.append(input())
for i in range(h):
	print(pic[i])
	print(pic[i])

Submission status: Accepted

Solution code:
h = int(input().split()[0])
for i in range(h):
  line = input()
  print(line)
  print(line)

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
for i in range(h):
    c = input()
    for i in range(2):
      print(c)

Submission status: Accepted

Solution code:
H,W=list(map(int,input().split(" ")))
C=[]

# 入力
for h in range(H):
    C.append(input())

# 出力、2回同じ行を出力すればOK
for h in range(H):
    print(C[h])
    print(C[h])