#include <stdio.h>
typedef long long ll;

int main(void) {
  ll i, j, n, ans = 0;
  scanf("%lld", &n);
  ll a[n];
  for(i = 0; i < n; ++i) scanf("%lld", &a[i]), ans ^= a[i];
  for(i = 0; i < n; ++i) printf("%lld ", ans ^ a[i]);
  return 0;
}