You are viewing a single comment's thread. Return to all comments →
Not a one liner. But easy to understand.
a,b=(int(input()),input().split()) c,d=(int(input()),input().split()) x=set(b) y=set(d) p=y.difference(x) q=x.difference(y) r=p.union(q) print ('\n'.join(sorted(r, key=int)))
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 →
Not a one liner. But easy to understand.