#include <bits/stdc++.h>
using namespace std;
template <class T>
inline bool CHMAX(T& a, T b) {
  if (a < b) {
    a = b;
    return true;
  }
  return false;
}
template <class T>
inline bool CHMIN(T& a, T b) {
  if (a > b) {
    a = b;
    return true;
  }
  return false;
}
constexpr long long INF = 1e18;
signed main() {
  long long N;
  cin >> N;
  vector<long long> a(N);
  for (auto& e : a) cin >> e;
  long long ma = -1, bit = -1;
  for (long long j = 0; j < (long long)(61); j++) {
    long long cnt = 0;
    for (long long i = 0; i < (long long)(N); i++) {
      if (a[i] % (1ll << j)) continue;
      if ((a[i] / (1ll << j)) % 2) cnt++;
    }
    if (CHMAX(ma, cnt)) bit = j;
  }
  vector<long long> ans;
  for (long long i = 0; i < (long long)(N); i++) {
    if (a[i] % (1ll << bit) == 0 && (a[i] / (1ll << bit)) % 2) continue;
    ans.push_back(a[i]);
  }
  cout << ans.size() << endl;
  for (long long i = 0; i < (long long)(ans.size()); i++)
    cout << ans[i] << " \n"[i + 1 == ans.size()];
}
