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())
for i in range(H):
  C = input()
  print(C)
  print(C)

Submission status: Accepted

Solution code:
# abc049_b.py
H,W = map(int,input().split())
C = []
for i in range(H):
    C.append(input())
for i in range(2*H):
    print(C[i//2])

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# Vicfred
# https://atcoder.jp/contests/abc049/tasks/abc049_b
# simulation
h, w = list(map(int, input().split()))
for _ in range(h):
    line = input()
    print(line)
    print(line)

Submission status: Accepted

Solution code:
h,w=map(int,input().split())
a=[input() for _ in range(h)]
for i in a:
  print(i)
  print(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:
def output() : 
  H, W = tuple(map(int, input().split()))
  
  for i in range(H) :
    str = input()
    print(str)
    print(str)
    
output()

Submission status: Accepted

Solution code:
#ABC 049 B - たてなが
H, W = map(int, input().split())
result = [""] * (H*2)
for i in range(H):
    C = input()
    for j in range(W):
        result[2 * i] = C
        result[2 * i + 1] = C
for i in range(H * 2):
    print(result[i])

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
C = [input() for _ in range(H)]
print("\n".join(c + "\n" + c for c in C))

Submission status: Accepted

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

for i in range(0,H):
  arr = input()
  ans.append(arr)
  ans.append(arr)

for i in range(0,H*2):
  print(ans[i])

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

for i in range(h):
  print(Ans[2*i])
  print(Ans[2*i+1])

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
C = [] * H
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 = [list(input()) for x 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):
    s = input()
    print(s)
    print(s)

Submission status: Accepted

Solution code:
"""
N = list(map(int,input().split()))
S = [str(input()) for _ in range(N)]
S = [list(map(int,list(input()))) for _ in range(h)] 
print(*S,sep="")
"""

import sys
sys.setrecursionlimit(10**6)
input = lambda: sys.stdin.readline().rstrip()
inf = float("inf") # 無限

h,w = map(int,input().split())
for _ in range(h):
    temp = input()
    for __ in range(2):
        print(temp)

Submission status: Accepted

Solution code:
H, W = map(int, input().split())
C = [input() for _ in range(H)]
for i in range(1, 2 * H + 1):
    for j in range(1, W + 1):
        print(C[((i + 1) // 2) - 1][j - 1], end='')
    print()

Submission status: Accepted

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

Submission status: Accepted

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

a=[]
for i in range(h):
  b=input()
  a.append(b)
  a.append(b)
for i in range(2*h):
  print(a[i])

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
import math
def I():return int(sys.stdin.readline().replace("\n",""))
def I2():return map(int,sys.stdin.readline().replace("\n","").split())
def S():return str(sys.stdin.readline().replace("\n",""))
def L():return list(sys.stdin.readline().replace("\n",""))
def Intl():return [int(k) for k in sys.stdin.readline().replace("\n","").split()]
def Lx(k):return list(map(lambda x:int(x)*-k,sys.stdin.readline().replace("\n","").split()))

h, w = I2()
c = [S() for _ in range(h)]
#print("------------------")
for i in range(2*h):
    print(c[i//2])

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 = 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())
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()
for a in range(h):
    c = input()
    ans.append(c)
    ans.append(c)

for a in range(h*2):
    print(ans[a])

Submission status: Accepted

Solution code:
n, m = map(int, input().split())
for i in range(n):
    x = input()
    for j in range(2):
        print(x)

Submission status: Accepted

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

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

Submission status: Accepted

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

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()
  print(s)
  print(s)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
h,w=map(int,input().split())
ans=[]
for i in range(h):
  temp=list(map(str,input()))
  ans.append(temp)
  ans.append(temp)
for i in range(h*2):
  print("".join(ans[i]))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

D = []
for i in range(2*H):
    D.append(C[i//2])
    print(''.join(D[i]))

Submission status: Accepted

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

for index in c:
    print(index)
    print(index)

Submission status: Accepted

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

ans = [[''] * w for _ in range(2 * h)]

for i in range(2 * h):
    for j in range(w):
        ans[i][j] = c[i // 2][j]

for line in ans:
    print(''.join(line))

Submission status: Accepted

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

for i in range(H):
  str_array = input()
  h.append(str_array)
  h.append(str_array)

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
for i in range(h):
    c = input()
    print('{}\n{}'.format(c, c))

Submission status: Accepted

Solution code:
h, w = map(int, input().split())
c = []
for i in range(h):
    c.append(input())
    print('{}\n{}'.format(c[i], c[i]))

Submission status: Accepted

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

ans = []
for c in C:
    for _ in range(2):
        ans.append(c)

for a in ans:
    print(a)

Submission status: Accepted

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

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


if __name__ == "__main__":
    main()

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())
picture = []
for i in range(h):
    c = list(input())
    picture.append(c)
    picture.append(c)

for j in range(2*h):
    print("".join(picture[j]))

Submission status: Accepted

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

data_list = []
#data_list = [ list(map(str,input().split(" "))) for i in range(H)]
for i in range(H):
  l = input()
  data_list.append(l)
  data_list.append(l)
  
for i in data_list:
  print(i)

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 = [input() for _ in range(H)]
for i in range(2*H):
  print(C[i//2])

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# coding: utf-8
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())
for i in range(H):
  n=input()
  print(n)
  print(n)

Submission status: Accepted

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

for i in range(0,h):
  c[i] = input().split()


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

Submission status: Accepted

Solution code:
H,W = map(int, input().split())
C = [0 for _ in range(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:
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):
    cc = input()
    c.append(cc)
    c.append(cc)

for i in range(h*2):
    print(c[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:
from math import *

def cin(): # To take limited number of inputs
    return map(int,input().split())

def cins(): # To take space sepreated strings
    return input.split()

def cino(test=False): # To take individual int input (test = False)
    if not test:
        return int(input())
    else: # To take string input (test = True)
        return input()

def cina(): # array input
  return list(map(int,input().split()))

def ssplit(): # multiple string input
    return list(input().split())

def printlist(l): # To print space seperated array
    for i in l:
        print(i,end=" ")

def main():
    a,b = cin()
    l = []
    for i in range(a):
        c = list(input())
        l.append(c)
    # print(l[1][0])
    for i in range(2*a):
        for j in range(b):
            print(l[i//2][j],end="")
        print("")


if __name__ == '__main__':
    main()

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:
def inp():
    return(int(input()))


# For taking List inputs.
def inlist():
    return(list(map(int, input().split())))


# For taking string inputs. Actually it returns a List of Characters, instead of a string, which is easier to use in Python, because in Python, Strings are Immutable.
def instr():
    s = input()
    return(list(s[:len(s)]))


# For taking space seperated integer variable inputs.
def invr():
    return(map(int, input().split()))


H, W = invr()
C = []
for i in range(H):
    temp = instr()
    C.append(temp)

for i in range(2*H):
    temp = ""
    for j in range(W):
        temp += C[i//2][j]
    print(temp)

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 = list(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 _ in range(H):
    s = input()
    print(s, flush=True)
    print(s, flush=True)

Submission status: Accepted

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

Submission status: Accepted

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

#############
# Libraries #
#############

import sys
input = sys.stdin.readline

import math
#from math import gcd
import bisect
from collections import defaultdict
from collections import deque
from functools import lru_cache


#############
# Constants #
#############

MOD = 10**9+7
INF = float('inf')

#############
# Functions #
#############

######INPUT######
def I(): return int(input().strip())
def S(): return input().strip()
def IL(): return list(map(int,input().split()))
def SL(): return list(map(str,input().split()))
def ILs(n): return list(int(input()) for _ in range(n))
def SLs(n): return list(input().strip() for _ in range(n))
def ILL(n): return [list(map(int, input().split())) for _ in range(n)]
def SLL(n): return [list(map(str, input().split())) for _ in range(n)]

######OUTPUT######
def P(arg): print(arg); return
def Y(): print("Yes"); return
def N(): print("No"); return
def E(): exit()
def PE(arg): print(arg); exit()
def YE(): print("Yes"); exit()
def NE(): print("No"); exit()

#####Shorten#####
def DD(arg): return defaultdict(arg)


#####Inverse#####
def inv(n): return pow(n, MOD-2, MOD)

######Combination######
kaijo_memo = []
def kaijo(n):
  if(len(kaijo_memo) > n):
    return kaijo_memo[n]
  if(len(kaijo_memo) == 0):
    kaijo_memo.append(1)
  while(len(kaijo_memo) <= n):
    kaijo_memo.append(kaijo_memo[-1] * len(kaijo_memo) % MOD)
  return kaijo_memo[n]

gyaku_kaijo_memo = []
def gyaku_kaijo(n):
  if(len(gyaku_kaijo_memo) > n):
    return gyaku_kaijo_memo[n]
  if(len(gyaku_kaijo_memo) == 0):
    gyaku_kaijo_memo.append(1)
  while(len(gyaku_kaijo_memo) <= n):
    gyaku_kaijo_memo.append(gyaku_kaijo_memo[-1] * pow(len(gyaku_kaijo_memo),MOD-2,MOD) % MOD)
  return gyaku_kaijo_memo[n]

def nCr(n,r):
  if(n == r):
    return 1
  if(n < r or r < 0):
    return 0
  ret = 1
  ret = ret * kaijo(n) % MOD
  ret = ret * gyaku_kaijo(r) % MOD
  ret = ret * gyaku_kaijo(n-r) % MOD
  return ret

######Factorization######
def factorization(n):
  arr = []
  temp = n
  for i in range(2, int(-(-n**0.5//1))+1):
    if temp%i==0:
      cnt=0
      while temp%i==0: 
        cnt+=1 
        temp //= i
      arr.append([i, cnt])
  if temp!=1:
    arr.append([temp, 1])
  if arr==[]:
    arr.append([n, 1])
  return arr

#####MakeDivisors######
def make_divisors(n):
  divisors = []
  for i in range(1, int(n**0.5)+1):
    if n % i == 0:
      divisors.append(i)
      if i != n // i: 
        divisors.append(n//i)
  return divisors

#####LCM#####
def lcm(a, b):
    return a * b // gcd (a, b)

#####BitCount#####
def count_bit(n):
  count = 0
  while n:
    n &= n -1
    count += 1
  return count

#####ChangeBase#####
def base_10_to_n(X, n):
  if X//n:
    return base_10_to_n(X//n, n)+[X%n]
  return [X%n]

def base_n_to_10(X, n):
  return sum(int(str(X)[-i])*n**i for i in range(len(str(X))))

#####IntLog#####
def int_log(n, a):
  count = 0
  while n>=a:
    n //= a
    count += 1
  return count

#############
# Main Code #
#############

H,W = IL()

for _ in range(H):
  s = S()
  P(s)
  P(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:
h, w = list(map(int, input().split()))
c_list = [list(input()) for _ in range(h)]

for i in range(len(c_list) * 2):
    for j in range(len(c_list[0])):
        print(c_list[min((i) // 2, h - 1)][j], end="")
    print()

Submission status: Accepted

Solution code:
from sys import stdin
def S(): return stdin.readline().rstrip()
def LI(): return list(map(int,stdin.readline().rstrip().split()))

tmp = LI()
h,w = [tmp.pop(0) for i in range(2)]

c = []

for i in range(h):
    tmp = S()
    c.append(tmp)

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

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 = [[0]*w for i in range(h*2)]
for i in range(h):
    dum = list(input().split())
    print("".join(dum))
    print("".join(dum))

Submission status: Accepted

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

import sys
# import time
# import math
# import numpy as np
# import scipy.sparse.csgraph as cs            # csgraph_from_dense(ndarray, null_value=inf), bellman_ford(G, return_predecessors=True), dijkstra, floyd_warshall
# import random                                # random, uniform, randint, randrange, shuffle, sample
# import string                                # ascii_lowercase, ascii_uppercase, ascii_letters, digits, hexdigits
# import re                                    # re.compile(pattern) => ptn obj; p.search(s), p.match(s), p.finditer(s) => match obj; p.sub(after, s)
# from bisect import bisect_left, bisect_right # bisect_left(a, x, lo=0, hi=len(a)) returns i such that all(val<x for val in a[lo:i]) and all(val>-=x for val in a[i:hi]).
# from collections import deque                # deque class. deque(L): dq.append(x), dq.appendleft(x), dq.pop(), dq.popleft(), dq.rotate()
# from collections import defaultdict          # subclass of dict. defaultdict(facroty)
# from collections import Counter              # subclass of dict. Counter(iter): c.elements(), c.most_common(n), c.subtract(iter)
# from datetime import date, datetime          # date.today(), date(year,month,day) => date obj; datetime.now(), datetime(year,month,day,hour,second,microsecond) => datetime obj; subtraction => timedelta obj
# from datetime.datetime import strptime       # strptime('2019/01/01 10:05:20', '%Y/%m/%d/ %H:%M:%S') returns datetime obj
# from datetime import timedelta               # td.days, td.seconds, td.microseconds, td.total_seconds(). abs function is also available.
# from copy import copy, deepcopy              # use deepcopy to copy multi-dimentional matrix without reference
# from functools import reduce                 # reduce(f, iter[, init])
# from functools import lru_cache              # @lrucache ...arguments of functions should be able to be keys of dict (e.g. list is not allowed)
# from heapq import heapify, heappush, heappop # built-in list. heapify(L) changes list in-place to min-heap in O(n), heappush(heapL, x) and heappop(heapL) in O(lgn).
# from heapq import nlargest, nsmallest        # nlargest(n, iter[, key]) returns k-largest-list in O(n+klgn).
# from itertools import count, cycle, repeat   # count(start[,step]), cycle(iter), repeat(elm[,n])
# from itertools import groupby                # [(k, list(g)) for k, g in groupby('000112')] returns [('0',['0','0','0']), ('1',['1','1']), ('2',['2'])]
# from itertools import starmap                # starmap(pow, [[2,5], [3,2]]) returns [32, 9]
# from itertools import product, permutations  # product(iter, repeat=n), permutations(iter[,r])
# from itertools import combinations, combinations_with_replacement
# from itertools import accumulate             # accumulate(iter[, f])
# from operator import itemgetter              # itemgetter(1), itemgetter('key')
# from fractions import gcd                    # for Python 3.4 (previous contest @AtCoder)



def main():
    mod = 1000000007                # 10^9+7
    inf = float('inf')              # sys.float_info.max = 1.79...e+308
    # inf = 2 ** 64 - 1             # (for fast JIT compile in PyPy) 1.84...e+19
    sys.setrecursionlimit(10**6)    # 1000 -> 1000000
    def input(): return sys.stdin.readline().rstrip()
    def ii():    return int(input())
    def mi():    return map(int, input().split())
    def mi_0():  return map(lambda x: int(x)-1, input().split())
    def lmi():   return list(map(int, input().split()))
    def lmi_0(): return list(map(lambda x: int(x)-1, input().split()))
    def li():    return list(input())
    
    
    h, w = mi()
    for _ in range(h):
        s = input()
        print(s)
        print(s)


if __name__ == "__main__":
    main()

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

for line in str_image:
    print(line)
    print(line)

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())
C = []
for i in range(H):
    c = input()
    C.append(c)
    C.append(c)
for i in range(2*H):
    print(C[i])

Submission status: Accepted

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

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

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:
def main():
    h, w = map(int, input().split())

    for i in range(h):
        s = input()
        print(s + '\n' + s + '\n')

main()

Submission status: Accepted

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

Submission status: Accepted

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

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

main()

Submission status: Accepted

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

portrait = []
for i in range(2*h):
    for j in range(w):
        print(m[int(i/2)][j], end='')
    print()

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
H, W = map(int, input().split())
for i in range(H):
    ln = input()
    print(ln)
    print(ln)

Submission status: Accepted

Solution code:
from sys import exit

ii = lambda : int(input())
mi = lambda : map(int,input().split())
li = lambda : list(map(int,input().split()))

h,w = mi()
cs = [input() for i in range(h)]

for i in range(h):
    for k in range(2):
        for j in range(w):
            print(cs[i][j],end="")
        print("")

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
import sys
sys.setrecursionlimit(10**9)
INF=10**18
MOD=10**9+7
input=lambda: sys.stdin.readline().rstrip()
YesNo=lambda b: bool([print('Yes')] if b else print('No'))
YESNO=lambda b: bool([print('YES')] if b else print('NO'))
int1=lambda x:int(x)-1

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:
h,m=map(int,input().split())
a=[input()for i in range(h)]
for i in a:
  print(i)
  print(i)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
H,W = map(int,input().split())
l=[]
for i in range(H):
    l.append(list(input()))
for i in range(H):
    for count in range(2):
        for j in range(W):
            if j==W-1:
                print(l[i][j])
            else:
                print(l[i][j],end='')

Submission status: Accepted

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

Submission status: Accepted

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

ans = []

for i in range(H):
    tmp = input()
    ans.append(tmp)
    ans.append(tmp)

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

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
"""
Created on Thu May 14 17:42:30 2020

@author: shinba
"""

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

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

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 = [int(i) for i in input().split()]
cc = []
for _ in range(H):
    cc.append(input())

for i in range(2 * H):
    print(cc[i // 2])

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 _ in range(h):
    S = input()
    for _ in range(2):
        print(S)

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 = tuple(map(int,input().split()))

s = [input() for _ in range(h)]

for s_i in s:
  print(s_i)
  print(s_i)

Submission status: Accepted

Solution code:
H,W=map(int,input().split())
C=[list(map(str,input().split())) for i in range(H)]
for i in range(2*H):
    print("".join(C[(i)//2]))

Submission status: Accepted

Solution code:
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians, log2
from itertools import accumulate, permutations, combinations, product, groupby
from operator import itemgetter, mul
from copy import deepcopy, copy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
import numpy as np
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

H, W = MAP()
C = [input() for _ in range(H)]

for x in C:
	print(x)
	print(x)

Submission status: Accepted

Solution code:
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians, log2
from itertools import accumulate, permutations, combinations, product, groupby
from operator import itemgetter, mul
from copy import deepcopy, copy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
import numpy as np
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

H, W = MAP()
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())
c_list = [input() 
          for nesya in range(h)]
for c in c_list:
  print(c)
  print(c)

Submission status: Accepted

Solution code:
H, _ = map(int, input().split())
for _ in range(H):
    row = input()
    print(row, row, sep="\n")

Submission status: Accepted

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

ans = []
for _ in range(h):
  c = input()
  for _ in range(2):
    ans.append(c)
    
for a in ans:
  print(a)

Submission status: Accepted

Solution code:
h,w = map(int, input().split())
for _ 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):
  cw = input()
  print(cw)
  print(cw)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

for i in range(H):
    c = input()
    C.append(c)
for i in range(H):
    for j in range(2):
        print(C[i])

Submission status: Accepted

Solution code:
N,M = map(int,input().split())
S = [input() for i in range(N)]
for j in range(N):
  print(S[j])
  print(S[j])

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())
c = [input() for _ in range(h)]
for i in c:
  print(i)
  print(i)

Submission status: Accepted

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

C = [input() for i in range(H)]
D = []
for i in range(H):
  D.append(C[i])
  D.append(C[i])

for i in range(H*2):
  print(D[i])