BOJ - 9093 - 단어 뒤집기
Updated:
import sys
def solution():
N = int(sys.stdin.readline())
for _ in range(N):
syntax = list(map(str, sys.stdin.readline().split(' ')))
syntax[-1] = syntax[-1].replace('\n', '')
for i in range(len(syntax)):
syntax[i] = syntax[i][::-1]
print(" ".join(syntax))
solution()
https://www.acmicpc.net/problem/9093
Leave a comment