#include <bits/stdc++.h>
#pragma GCC optimize(3)
#pragma GCC optimize("Ofast")
#pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native")
#pragma comment(linker, "/stack:200000000")
using namespace std;
void io() {
  ios::sync_with_stdio(false);
  cin.tie(nullptr);
  cout.tie(nullptr);
}
long long n, m, T, k1, k2, num;
int t[301000 << 1], pos[301000];
struct Point {
  long long x, y;
} p[301000];
int main() {
  io();
  cin >> n;
  for (long long i = 1; i <= n; ++i) cin >> p[i].x >> p[i].y;
  for (long long i = 1; i <= n; ++i) p[i].x += 1e6, p[i].y += 1e6;
  bool f = true;
  vector<int> vec[5];
  while (f) {
    for (long long i = 1; i <= 4; ++i) vec[i].clear();
    for (long long i = 1; i <= n; ++i) {
      if ((p[i].x & 1) && (p[i].y & 1))
        vec[1].emplace_back(i);
      else if (!(p[i].x & 1) && !(p[i].y & 1))
        vec[2].emplace_back(i);
      else if ((p[i].x & 1) && !(p[i].y & 1))
        vec[3].emplace_back(i);
      else if (!(p[i].x & 1) && (p[i].y & 1))
        vec[4].emplace_back(i);
    }
    num = 0;
    for (long long i = 1; i <= 4; ++i)
      if (vec[i].size()) ++num;
    if (num > 1)
      f = false;
    else
      for (long long i = 1; i <= n; ++i) p[i].x >>= 1, p[i].y >>= 1;
  }
  if (num > 2) {
    cout << vec[1].size() + vec[2].size() << '\n';
    for (auto i : vec[1]) cout << i << ' ';
    for (auto i : vec[2]) cout << i << ' ';
  } else {
    for (long long i = 1; i <= 4; ++i) {
      if (vec[i].size()) {
        cout << vec[i].size() << '\n';
        for (auto i : vec[i]) cout << i << ' ';
        return 0;
      }
    }
  }
}
