def resolve():
    n=int(input())
    a=list(map(int,input().split()))
    for i in range(n):
        ans=0
        for j in range(n):
            if j==i:
                continue
            ans=ans^a[j]
        print(ans)

if __name__ == '__main__':
    resolve()