#include <bits/stdc++.h>
using namespace std;
void solve() {
  long long int n, maxi = -1e18, maxind = -1;
  vector<long long int> v[64];
  cin >> n;
  for (long long int i = 0; i < (n); i++) {
    long long int x;
    cin >> x;
    for (long long int j = 0; j < (64); j++) {
      if ((1LL << j) & x) {
        v[j].push_back(x);
        long long int sz = v[j].size();
        if (maxi < sz) {
          maxi = v[j].size();
          maxind = j;
        }
        break;
      }
    }
  }
  cout << n - maxi << endl;
  for (long long int i = 0; i < (64); i++) {
    if (!v[i].empty() && i != maxind) {
      for (auto e : v[i]) cout << e << " ";
    }
  }
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  ;
  long long int t = 1;
  while (t--) {
    solve();
  }
}
