You are viewing a single comment's thread. Return to all comments →
m = int(input())
a = set(map(int, input().split()[:m]))
n = int(input())
b = set(map(int, input().split()[:n]))
result = a ^ b
for item in sorted(result):
print(item)
Seems like cookies are disabled on this browser, please enable them to open this website
Symmetric Difference
You are viewing a single comment's thread. Return to all comments →
m = int(input())
a = set(map(int, input().split()[:m]))
n = int(input())
b = set(map(int, input().split()[:n]))
result = a ^ b
for item in sorted(result):