cnt = int(input()) lists = [] for i in range(cnt): inp = list(map(int, input().split())) print(set(inp)) inp.clear() print(inp)