#include "bits/stdc++.h"
using namespace std;

typedef long long ll;

int main() {
	ll n, s = 0;
	cin >> n;
	vector<ll> A(n);
	for (auto& a: A)
	{
		cin >> a;
		s ^= a;
	}
	
	for (auto a: A)
		cout << (s ^ a) << endl;
	
	return 0;
}